Is it only because it is easier to display the query in the query-design
table?
Yes, I believe EM changes the query to facilitate GUI display.
Or is it actually a more efficient method?
SQL is declarative rather than procedural. The optimizer in the database
engine will try to generate the most efficient plan regardless of how the
query is expressed. If you compare the execution plans of the 2 queries in
Query Analyzer, I would expect both to be identical because they are
semantically identical.
--
Hope this helps.
Dan Guzman
SQL Server MVP
http://weblogs.sqlteam.com/dang/
"Leif Neland" <le**@neland.dkwrote in message
news:48***********************@dtext01.news.tele.d k...
When I use "sql server enterprise manager" gui and write an expression
like
where a=1 and (b=2 or c=3)
it gets transformed into
where (a=1 and b=2)
or (a=1 and c=3)
Is it only because it is easier to display the query in the query-design
table?
Or is it actually a more efficient method?
I.e, when I take the finished query and paste it into my asp-source,
should I keep the transformed query, which is larger, or transform it back
to the way I originally wrote it?
Leif