[AccessD] Correct syntax for parameter query

Hale, Jim Jim.Hale at FleetPride.com
Thu Aug 26 14:06:36 CDT 2004


I am currently doing the following to create a recordet from an existing
parameter query:

qryString(7) = "qryPlanHistCYplan_Upload_Improved"

Set qdfTemp(7) = dbs2.QueryDefs(qryString(7))
    qdfTemp(7).Parameters(strParameters(1)) = intDept
    qdfTemp(7).Parameters(strParameters(2)) = intCo
    qdfTemp(7).Parameters(strParameters(3)) = strCatcode1
    qdfTemp(7).Parameters(strParameters(4)) = "sales" 
    qdfTemp(7).Parameters(strParameters(5)) = strPlGroup

Set recset(7) = qdfTemp(7).OpenRecordset()

This works fine. However, I need to change parameter(4) into something like
the following
 qdfTemp(7).Parameters(strParameters(4)) = "sales or misc" 
I can't seem to get the syntax right. Can anyone tell me the correct syntax?
TIA

Jim Hale




More information about the AccessD mailing list