Re: Problem with Query based on HTML form values - Clarification

2002-12-18 Thread Bill Lovett
You have it right. But if the user searches for new power boats, and doesn't specify a make, make should not appear in your WHERE clause. The query has to be different depending on the criteria that have been chosen (or not chosen, as the case may be). Prior to executing the query, look at all

Re: Problem with Query based on HTML form values - Clarification

2002-12-17 Thread web-dev
Bill Lovett wrote: Hello, You're getting all new boats + all sail boats + all boats of type x because you're using ORs. If you only want records that match all the criteria, use ANDs instead. If I use AND, wouldn't all conditions need to be true to return a result? In the case of the