$query = 'select * from table where fieldname in(\''. implode('\',\'',$myArray) . '\')';

Roy W wrote:

I have a bunch of variables stuffed in myArray()

I want to run a MySQL SELECT statement ($query=" ......") where it will
access only those records in the database "WHERE" table.fieldname is found
in myArray

Is there a simple one liner?  Or do I have to "loop" it through (kinda nasty
as you can imagine)

Help anyone?

Thanks!! :-))




-- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law.



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to