Parameter Query and IN clause

BoghRD
11-20-2000, 12:03 PM
Is there a way to send a list of strings like:
"'BLAH01','BLAH02','BLAH03'"

as a parameter into a parameter query like the following:

PARAMETERS cPlatoonList Text, dteMRDate DateTime;
SELECT Demographic.SSN, Demographic.Platoon, Status.Status, Status.SubCategory, Status.StatusRemarks, Status.DateBegin, Status.DateEnd, Status.WhoModified, Status.DateModified
FROM Demographic LEFT JOIN Status ON Demographic.SSN = Status.SSN
WHERE (
(Demogrphic.Platoon IN ([cPlatoonList])) AND '<--- Here
((DateValue([Status].[DateBegin]))<=[dteMRDate]) AND ((DateValue([Status].[DateEnd]))>=[dteMRDate]))

The problem seems to revolve around the parser stripping the single quotes off the string of platoons as they are submitted into the query as parameters. Basically, is there a different syntax for using a parameter in an IN clause...

Roger Bogh

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum