If your db supprots it, you can use the minus union feature too. I
think its just sq2k and oracle.  Basically select all the ids then do
a minus union with a selection of the ids in the second table.

DRE

On 8/19/05, Tony Weeg <[EMAIL PROTECTED]> wrote:
> gel here it is...
> 
> select a,b,count(*)
>         from test
>         group by a,b
>         having count(*) > 1
> 
> 
> On 8/19/05, Vivec <[EMAIL PROTECTED]> wrote:
> > I can do this with two queries, but I seem to remember there's a way
> > to do it with just one.
> >
> > I have two tables, Table1 and Table2.
> >
> > I want a recordset containing all the Table2 IDs that are NOT in the
> > Table1 table.
> > I know there's an SQL statement, a join, to do that..but I just can't
> > remember it!
> > 0_0
> >
> >
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:5:170431
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/5
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:5
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.5
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to