Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-17 Thread kvigor
Hello Master Coders, This is working so far but I need to add an additional search. This is what I have so far: $in_list = "'".join("','",$cen_chiefs)."'"; $query_cen_chiefs = "SELECT * FROM central WHERE CONCAT(strName,' ',strCity,' ',strState) IN({$in_list}) ORDER BY conName"; I a

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-17 Thread kvigor
ginal Message - From: "Jim Lucas" <[EMAIL PROTECTED]> >> To: "kvigor" <[EMAIL PROTECTED]> >> Cc: >> Sent: Saturday, June 30, 2007 1:46 AM >> Subject: Re: [PHP] Selecting Rows Based on Row Values Being in Array >> >> >&

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-05 Thread Jim Lucas
ame,' ',strCity,' ',strState) it worked. So what do I owe you? - Original Message - From: "Jim Lucas" <[EMAIL PROTECTED]> To: "kvigor" <[EMAIL PROTECTED]> Cc: Sent: Thursday, July 05, 2007 10:10 AM Subject: Re: [PHP] Selecting Rows Bas

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-05 Thread K. Hayes
,strCity,' ',strState) it worked. So what do I owe you? - Original Message - From: "Jim Lucas" <[EMAIL PROTECTED]> To: "kvigor" <[EMAIL PROTECTED]> Cc: Sent: Thursday, July 05, 2007 10:10 AM Subject: Re: [PHP] Selecting Rows Based on Row Values

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-05 Thread Jim Lucas
kvigor wrote: Sorry, That was a typo there's on one IN clause. here is how it reads: SELECT * FROM central WHERE CONCAT(strName,strCity,strState) IN('7orange50lbs','8purple60lbs'). So in my table I have 8 in size column, purple in color column, and 60lbs in weight column. Since the concaten

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-05 Thread kvigor
Sorry, That was a typo there's on one IN clause. here is how it reads: SELECT * FROM central WHERE CONCAT(strName,strCity,strState) IN('7orange50lbs','8purple60lbs'). So in my table I have 8 in size column, purple in color column, and 60lbs in weight column. Since the concatenated value will be

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-05 Thread Jim Lucas
kvigor wrote: where is the part that it join()'s things together? it's: $in_list = "'".join("','",$list)."'"; Good what is the output of the join() call it's: '7orange50lbs','8purple60lbs' //once echo'd Fine $query_One = "SELECT * FROM shoe WHERE CONCAT(size,color,weight) IN({$in_lis

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-04 Thread kvigor
>>where is the part that it join()'s things together? it's: $in_list = "'".join("','",$list)."'"; >>what is the output of the join() call it's: '7orange50lbs','8purple60lbs' //once echo'd $query_One = "SELECT * FROM shoe WHERE CONCAT(size,color,weight) IN({$in_list})"; This is the results of $

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-03 Thread Jim Lucas
kvigor wrote: Jim, Thanks for all you help. Tell me where to mail you the check "seriously". If we get this right I'll owe you. OK, the query string now looks like you said it would. However Query isn't returning a match. //DETAILS=

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-03 Thread Chris
kvigor wrote: Jim, Thanks for all you help. Tell me where to mail you the check "seriously". If we get this right I'll owe you. OK, the query string now looks like you said it would. However Query isn't returning a match. //DETAILS=

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-03 Thread kvigor
Jim, Thanks for all you help. Tell me where to mail you the check "seriously". If we get this right I'll owe you. OK, the query string now looks like you said it would. However Query isn't returning a match. //DETAILS= My $list array lo

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-03 Thread Jim Lucas
kvigor wrote: Ok Jim, This is what I have so far and I'm still working it out. $in_list = "".join('',$someArrayList); // do I really need to concatenate it needs to be $in_list = "'".join("','",$someArrayList)."'"; // you need the quotes!! or separate anything here since my array v

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-02 Thread Richard Lynch
I don't even being to understand your question, but it's a MySQL question anyway. http://dev.mysql.com/ On Sat, June 30, 2007 12:18 am, kvigor wrote: > Hello All, > > I'm attempting to return rows from a mysql DB based on this criteria: > > I have a list, in the form of an array that I need to co

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-02 Thread kvigor
each, and haven't seen comparable code. >> >> I'm asking because I don't know where we're telling the code to compare >> the values. >> >> You stated... >>>>> and create one string from them >> Where do I give the name to the

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-01 Thread Jim Lucas
So this is where I am so far: $sql = "SELECT* FROM table WHERE CONCAT(size,color,weight) IN( )"; "Jim Lucas" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] K. Hayes wrote: Will do. Thanks. - Original Message - From: "Jim Lucas" <

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-07-01 Thread kvigor
. >> >> >> - Original Message - From: "Jim Lucas" <[EMAIL PROTECTED]> >> To: "kvigor" <[EMAIL PROTECTED]> >> Cc: >> Sent: Saturday, June 30, 2007 1:46 AM >> Subject: Re: [PHP] Selecting Rows Based on Row Values Being in

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-06-29 Thread Jim Lucas
K. Hayes wrote: Will do. Thanks. - Original Message - From: "Jim Lucas" <[EMAIL PROTECTED]> To: "kvigor" <[EMAIL PROTECTED]> Cc: Sent: Saturday, June 30, 2007 1:46 AM Subject: Re: [PHP] Selecting Rows Based on Row Values Being in Array kvigor wrote

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-06-29 Thread K. Hayes
Will do. Thanks. - Original Message - From: "Jim Lucas" <[EMAIL PROTECTED]> To: "kvigor" <[EMAIL PROTECTED]> Cc: Sent: Saturday, June 30, 2007 1:46 AM Subject: Re: [PHP] Selecting Rows Based on Row Values Being in Array kvigor wrote: Hello All

Re: [PHP] Selecting Rows Based on Row Values Being in Array

2007-06-29 Thread Jim Lucas
kvigor wrote: Hello All, I'm attempting to return rows from a mysql DB based on this criteria: I have a list, in the form of an array that I need to compare against each row in the table. Where theres a match I need that entire row returned. e.g.$varListof 3outOf_10Fields = array(6blue4