Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.chainon-marquant.org!nntpfeed.proxad.net!proxad.net!feeder1-1.proxad.net!198.186.194.247.MISMATCH!news-out.readnews.com!transit3.readnews.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: "Fred." Newsgroups: comp.databases.ms-sqlserver Subject: Non-Relating Join Criteria Date: Wed, 2 Nov 2011 06:53:47 -0700 (PDT) Organization: http://groups.google.com Lines: 21 Message-ID: <12431962.894.1320242027343.JavaMail.geo-discussion-forums@yqbl36> Reply-To: comp.databases.ms-sqlserver@googlegroups.com NNTP-Posting-Host: 76.235.36.235 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: posting.google.com 1320242119 20235 127.0.0.1 (2 Nov 2011 13:55:19 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 2 Nov 2011 13:55:19 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=76.235.36.235; posting-account=H0CbGQoAAACbl_tS1RfYwvMt_jmh18zO User-Agent: G2/1.0 X-Google-Web-Client: true Xref: x330-a1.tempe.blueboxinc.net comp.databases.ms-sqlserver:773 Transact SQL apparently supports one-sided critera, such as the "a.SEL=15" in (1) below. in the join expression. I would expect that both (1) and (2) would return the same result set, and the examples I have tried match this expectation. My question is whether or not there can be a strong reason to prefer one over the other, such as impact on the order of evaluation. CREATE TABLE a (APK int PRIMARY KEY, SEL int, ... ) CREATE TABLE b (BPK int PRIMARY KEY, AFK int, ... ) (1) SELECT ... FROM a INNER JOIN b ON a.APK=b.AFK AND a.SEL=15 (2) SELECT ... FROM a INNER JOIN b ON a.APK=b.AFK WHERE a.SEL=15 Fred.