JOINS, EXISTS or IN which is better? Few questions on SQL

前端 未结 8 1795
不思量自难忘°
不思量自难忘° 2021-01-14 07:58

I have few questions on SQL..

  1. How to analyze the performance of a query? Any software, inbuilt features of MSSQL server 2005/2008?

  2. What shou

8条回答
  •  感情败类
    2021-01-14 08:57

    I guess the join gives more free to the engine for choice the best query plan. In your exactly case, probably have all solutions similar performances.

    SELECT enquiry_courses.* 
    FROM enquiry_courses 
    INNER JOIN enquiries ON enquiries.enquiry_id=enquiry_courses 
                            AND session_id = '4cd3420a16dbd61c6af58f6199ac00f1' 
    

提交回复
热议问题