Results 1 to 3 of 3

Thread: Ways to Achieve Query Optimization

  1. #1
    Contributing Member
    Join Date
    May 2006
    Answers
    72

    Ways to Achieve Query Optimization

    Hi,
    Some of the techniques for achieving optimization query are normalization, ER diagram. Can someone let me know some more techniques to achieve query optimization and also let me know the scenario or when to use the same.

    Regards,
    Joel


  2. #2
    Junior Member
    Join Date
    Dec 2006
    Answers
    3

    Re: Ways to Achieve Query Optimization

    Hi,
    some of the point for query optimization are :-
    1. Don't use trigger on Table.
    2.Minimize using Index on ur table.

    Thanks
    Santosh


  3. #3
    Junior Member
    Join Date
    Dec 2006
    Answers
    3

    Re: Ways to Achieve Query Optimization

    Hi,
    Go through the following point for Query Optimizations :-
    1. Use views and stored procedures instead of heavy-duty queries.
    2. Try to use constraints instead of triggers, whenever possible.
    3. Use table variables instead of temporary tables.
    4.Try to use UNION ALL statement instead of UNION, whenever possible.
    5. Try to avoid using the DISTINCT clause, whenever possible.
    6. Try to avoid using SQL Server cursors, whenever possible.
    7. Try to avoid the HAVING clause, whenever possible.
    8. Try to restrict the queries result set by using the WHERE clause.
    9.Use the select statements with TOP keyword or the SET ROWCOUNT statement, if you need to return only the first n rows.
    10.Try to restrict the queries result set by returning only the particular columns .


    Thanks & Regard's
    Santosh Kumar


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact