When you display the #templist# what does it look like? Not in SQL. Greg Luce eDiets.com 3801 W. Hillsboro Blvd Deerfield Beach, FL 33442 [EMAIL PROTECTED] 954.360.9022 x116
-----Original Message----- From: jgeorges [mailto:[EMAIL PROTECTED]] Sent: Wednesday, July 17, 2002 9:15 AM To: CF-Talk Subject: Build Query with IN in WHERE clause I have an array containing alphanumeric user ID's. I am trying to build a query that will select data if the user ID is in the array, i.e. select * from employee where userid in ('userid1','userid2',...,'useridn') I used and select * from employee where userid in ('#tempList#') This resolved to select * from employee where userid in ('userid1'',''userid2') which failed. I then built a string tempList = 'userid1','userid2' and used select * from employee where userid in (#tempList#) This resolved to select * from employee where userid in (''userid1'',''userid2'') which failed. I've tried building the whole SQL string in a variable with the same results. I tried using double quotes as well. I am using CF5 and SQL Server 6.5. Any Help would be appreciated. TIA, Sam ------------------------------------------------ Can a Web portal forever change your life? Win up to $25 Million on iWon - click here! ______________________________________________________________________ Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

