something like


<cfquery name="blah" ...>
select PKID
from myTable
where name not in (<CFQUERYPARAM VALUE="#attributes.myList#"
CFSQLTYPE="CF_SQL_VARCHAR" LIST="Yes">)
</cfquery>


altho make sure that there is something in the list... an empty list will
throw an error


HTH

-----Original Message-----
From: Won Lee [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 7, 2003 16:06
To: CF-Talk
Subject: cfquery + list

Hello,

Let's say I have a list:
<cfset attributes.myList = "John, Amy">

How can I do a query that would take that list and do a not in?

<cfquery name="blah" ...>
select PKID
from myTable
where name not in ('#attributes.myList#')
</cfquery>

(This codes doesn't work)

CF 5.0

  _____  


[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to