I don't know MySQL, never having used it, but I'd say it's probably similar
to: 

SELECT a.id,a.Name,a.ListCol, b.id, b.Name, b.ListCol
FROM Table_A a,  Table_B b
WHERE  a.id = b.id


Will that do what you want?

Cheers
Mike Kear
Windsor, NSW, Australia
Macromedia Certified Advanced ColdFusion Developer
AFP Webworks Pty Ltd
http://afpwebworks.com
Full Scale ColdFusion hosting from A$15/month



-----Original Message-----
From: Yves Arsenault [mailto:[EMAIL PROTECTED] 
Sent: Monday, 2 May 2005 2:25 PM
To: SQL
Subject: Comparing lists

Hello,

I would like to know if it is possible to compare 2 lists of numbers in a
query using MySQL 3.x or 4.0.

I've been looking at the docs, and so far haven't found what I'm looking
for..

Basically, say I have 2 tables.

Table_A - ID,Name,ListCol (containing a list of numbers)
Table_B - ID,Name,ListCol (containing another list of numbers)

What I would like to do in my query is to have Table_A.ListCol compare with
Table_B.ListCol, and if 1 number from Table_A matches with one of the
numbers from Table_B's list, then I've got a match.

Anyone ever do anything like this?

;-)

Thanks,

Yves



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
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:6:2260
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/6
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:6
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.6
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to