[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
faster select -Reply
- Subject: faster select -Reply
- From: Lynn Francis <lfrancis@ABA.COM>
- Date: Wed, 29 Jan 1997 16:27:44 -0500
Generally the "exists" format is preferable since the subquery simply
needs to find on row to qualify the statement as 'TRUE' .
Lynn Francis
American Bankers Association
>>> Angel Guzman <Angel_Guzman@TRFB.NAVY.MIL> 01/29/97
02:02pm >>>
Which of these selects would be more efficient/faster in comparing
data from two different databases?
from tt_shop
where department = $dept
and shop in (select master-shop from ldsloc.dbo.tt_shop)
! and exists (select master-shop from ldsloc.dbo.tt_shop
! where master-shop = shop)
order by department, division, branch, shop
Angel