Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
heze
Posting Yak Master
192 Posts |
Posted - 2007-02-16 : 15:51:08
|
| hi does anybody know the difference between:select * from mytab1 mleft join myTab2 m2 on m2.cond=1 and m2.id=m.id--andselect * from mytab1 mleft join myTab2 m2 on and m2.id=m.idwhere m2.cond=1--Tnank you |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-02-16 : 16:02:00
|
| What do the query plan tell you?Peter LarssonHelsingborg, Sweden |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-02-16 : 16:04:49
|
| [code]declare @t1 table (id int)insert @t1select 1 union allselect 2declare @t2 table (id int, cond int)insert @t2select 1, 1 union allselect 1, 5 union allselect 3, 1select * from @t1 mleft join @t2 m2 on m2.cond=1 and m2.id=m.idselect * from @t1 mleft join @t2 m2 on m2.id=m.idwhere m2.cond=1[/code]Peter LarssonHelsingborg, Sweden |
 |
|
|
|
|
|