Re: SQL Returns

2001-04-12 Thread Kevin Ward
Alan, You could limit your result set by telling the database to only return distinct Products.ItemID : SELECT distinct(Products.ItemID), ... Kevin At 06:57 AM 4/12/01 -1000, you wrote: I would like to refine my sql searches down. From the following sql statement I am recieving up to 12

RE: SQL Returns

2001-04-12 Thread Hayes, David
Is your join correct? Should it, perhaps, be WHERE products.ItemID = prodPics.itemID? Is there a 1 to 1 relationship between products and pics? -Original Message- From: Alan Koenig [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 12, 2001 11:58 AM To: CF-Talk Subject: SQL Returns I

RE: SQL Returns

2001-04-12 Thread Bob Silverberg
Well, one way it to use the DISTINCT keyword. Change your statement from: SELECT Products.ItemID, etc. to SELECT DISTINCT Products.ItemID, etc. but I'm not sure if that will give you what you want. Give it a try and see what the result set looks like. Bob -Original Message-

Re: SQL Returns

2001-04-12 Thread Alan Koenig
It is a 1 to 1 relationship between them. Thanks - Original Message - From: "Hayes, David" [EMAIL PROTECTED] To: "CF-Talk" [EMAIL PROTECTED] Sent: Thursday, April 12, 2001 7:21 AM Subject: RE: SQL Returns Is your join correct? Should it, perhaps, be W

Re: SQL Returns

2001-04-12 Thread Jeffry Houser
At 06:57 AM 04/12/2001 -1000, you wrote: I would like to refine my sql searches down. From the following sql statement I am recieving up to 12 returns of the same record. How can I make this so that there is only 1 return for each record? cfquery datasource="#datasource#" name="prodpage"

Re: SQL Returns

2001-04-12 Thread Alan Koenig
MAIL PROTECTED] Sent: Thursday, April 12, 2001 7:24 AM Subject: RE: SQL Returns Well, one way it to use the DISTINCT keyword. Change your statement from: SELECT Products.ItemID, etc. to SELECT DISTINCT Products.ItemID, etc. but I'm not sure if that will give you what you want. Give i

RE: SQL Returns

2001-04-12 Thread Evan Lavidor
BY ItemName otherwise that OR might be throwing some wrenches in there... HTH, Evan -Original Message- From: Alan Koenig [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 12, 2001 2:21 PM To: CF-Talk Subject: Re: SQL Returns That did not help, now I am getting 14 returns for each record

Re: SQL Returns

2001-04-12 Thread Jeffry Houser
CTED] Sent: Thursday, April 12, 2001 7:24 AM Subject: RE: SQL Returns Well, one way it to use the DISTINCT keyword. Change your statement from: SELECT Products.ItemID, etc. to SELECT DISTINCT Products.ItemID, etc. but I'm not sure if that will give you what you want. G

RE: SQL Returns

2001-04-12 Thread Christian L. Watt
lto:[EMAIL PROTECTED]] Sent: Thursday, April 12, 2001 5:54 PM To: CF-Talk Subject: Re: SQL Returns If you are using DISTINCT you will not get 14 identical returns for each record. There must be something else that is different. If you want to show us your table structure, and perhaps some samp