try a LEFT OUTER JOIN. That should work for you.
Jeff
----- Original Message -----
From: <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Monday, June 02, 2003 8:47 AM
Subject: SQL Question
I have a MS_SQL query (simplified for this question):
SELECT *
FROM product A,style B,quantity C
WHERE A.product_id = B.product_id AND
B.style_id = C.style_id AND
ORDER BY A.product,B.style,F.productSize
I have another table that contains images for some of the products.
I would like to get back all the products that have or don't
have images. I tried using a RIGHT JOIN but I couldn't get it
working correctly.
The images use the style_id to identify which style they belong
to. So B.style_id = D.style_id (D being images)
Thoughts?
Thanks,
BJ
___________________________________________________________
Sent by ePrompter, the premier email notification software.
Free download at http://www.ePrompter.com.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription:
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
This list and all House of Fusion resources hosted by CFHosting.com. The place for
dependable ColdFusion Hosting.
http://www.cfhosting.com
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4