Listbox Question

Results 1 to 4 of 4

Thread: Listbox Question

  1. #1
    Barkus Guest

    Default Listbox Question

    Using SQL 7.0, how do you get a query to result in all records shown. The catch is I still want to be able to narrow my search by using three different fields of city, state and keyword.<BR><BR>I&#039ve tried using a select all approach. Where:<BR>&#060;select name="State"&#062;<BR>&#060;option value="AL,AK,AZ....WA"&#062;ANY&#060;/option&#062;<BR>&#060;option value="AL"&#062;Alabama&#060;/option&#062;<BR>----<BR>&#060;/select&#062;<BR><BR>What resulted is ANY had to equal all the states or none.<BR><BR>Also, I had no problem in narrowing my search by using the fields city, state and keyword but when I want to broaden my search that is where I run into problems.<BR><BR>Please help!!!!<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Listbox Question

    Try setting the value of your &#039ANY&#039 option to "%" - the SQL wildcard.<BR><BR>HTH<BR><BR>Dunc

  3. #3
    Barkus Guest

    Default RE: Listbox Question

    Like the idea of using the wildcard!!!<BR><BR>However, when I tested it on the SQL Query Analyzer (Select * FROM RS Where State="%"), it resulted in no states selected.<BR><BR>Any other ideas<BR><BR>

  4. #4
    Barkus Guest

    Default RE: Listbox Question

    Thanks for the help!!! I was able to solve it

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts