M
mosscliffe
I am using Visual Studio with a MS Access Database
I just can not work out how to create my parameter for the following
Select Fld1, Fld2 from myTable where Fld1 in (?)
The value I wish to add to the parameter collection for Fld1 is '2, 3,
17, 9, 235'
to add a single Parameter I would do the following
cmd.parameters.add("",oledbtype.integer).value = 1
There does not seem to be an OleDbType for an integer array
But I don't have a single value and I do not know how many values,
there will be in the 'IN' query
I also have other parameters in the Selection (not shown) and as
OleDbParameters, seem to be positional, with no way of changing that, I
can't just enter many '?' into the 'IN' part and only enter as many as
I need. In any case what would happen if I had multiple 'IN'
comparators.
Any ideas or suggestions, welcomed
I just can not work out how to create my parameter for the following
Select Fld1, Fld2 from myTable where Fld1 in (?)
The value I wish to add to the parameter collection for Fld1 is '2, 3,
17, 9, 235'
to add a single Parameter I would do the following
cmd.parameters.add("",oledbtype.integer).value = 1
There does not seem to be an OleDbType for an integer array
But I don't have a single value and I do not know how many values,
there will be in the 'IN' query
I also have other parameters in the Selection (not shown) and as
OleDbParameters, seem to be positional, with no way of changing that, I
can't just enter many '?' into the 'IN' part and only enter as many as
I need. In any case what would happen if I had multiple 'IN'
comparators.
Any ideas or suggestions, welcomed