Building an SQL statement using access forms and VB.
I have an access form that has serach critera fileds taken from the user. I want to then efficently build an SQL string in VB.
How does one intelligently build an SQL statement from the fields they provide? To be more concrete about what I am asking; If I have say 10 possible criteria that I want to use in the SQL statement and I am collecting this from the user, I could have potentially 2^10 possible combinations of searches. How do I build the statement programmatically without writing out a separate SQL statement for every possible combination of search criteria that the user could enter?