How do you optimize SQL queries ?
Answer Posted / hutashan
Avoid implicit datatype conversion
Avoid using function on an indexed column
Avoid comparing column value with NULL
Outer Join
Use OR carefully
Always use NOT EXISTS instead of NOT IN
Use UNION ALL whenever possible (no implicit sorts)
UNION will sort the result set for each SELECT before
combining the final result set
Remove DISTINCT keyword from SELECT if UNION is used
Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
Is sql a backend?
What is date functions?
How do you write a complex sql query?
How do I remove duplicates in two columns?
What has stored procedures in sql and how we can use it?
Where can I learn sql for free?
What is sql and explain its components?
how to create a new table by selecting rows from another table in mysql? : Sql dba
How do you exit in sql?
How does index help in query performance?
When is the explicit cursor used ?
i have a column which may contain this kind of value: 123*67_80,12*8889_5,34*8_874 ,12*7_7 (can contain space before a comma, and this string length can be anything) now i want to split this value into two column like: column1: 123*67,12*8889,34*8,12*7 column2: 80,5,874,7 use function for this
What are the advantages of sql?
What are sql functions? Describe in brief different types of sql functions?
How do I count rows in sql?