build the IN caluse of an sql Statement

F

Fab

Hello,

I want to be able to allow the user to select (check box) from a table for
each row id to be included in a query.
i.e.

i have a table of names with an name id column. i.e

name id Name
1 fab
2 john
3 luke
4 kathy


now if the user check off Fab and Luke i would to build a query that will
be somthing like

select * from names where nameid IN (1,3).

i would to do this dynimically in VB code.

any ideas?
 
V

Van T. Dinh

How do the user "check" the names?

Do the user use the DatsheetView of the Table? A Form in CtsFormView? A
Multi-Select ListBox on the Form?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top