G
Guest
I have an Access 2000 stored query that I am trying to set criteria for in
VBA before running. I know I can create the whole query and criteria in VBA
using SQL statements but because of the number of fields involved I'm hoping
I can do this by making it a stored query instead. This will make it easier
to maintain later.
The criteria consists of a dynamic array of FileIDs. So the WHERE clause
should look something like:
"Where [FileID]=" & aryID(1) & " Or [FileID]=" & aryID(2) & " Or "etc...
I thought about using a parameter query and assigning the parameter value in
VBA but I can't figure out how to make the "OR" criteria for an undetermined
amount of FileIDs.
Any help is greatly appreciated.
VBA before running. I know I can create the whole query and criteria in VBA
using SQL statements but because of the number of fields involved I'm hoping
I can do this by making it a stored query instead. This will make it easier
to maintain later.
The criteria consists of a dynamic array of FileIDs. So the WHERE clause
should look something like:
"Where [FileID]=" & aryID(1) & " Or [FileID]=" & aryID(2) & " Or "etc...
I thought about using a parameter query and assigning the parameter value in
VBA but I can't figure out how to make the "OR" criteria for an undetermined
amount of FileIDs.
Any help is greatly appreciated.