Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FP 2000 Form: display all results when nothing selected from dropdown

Status
Not open for further replies.

njitter

Technical User
Sep 4, 2001
122
US
Hello,

i use a drop down box to query a database.

When someone selects a value from the drop-down box the asp page will query the database to show results that match that parameter (after he clicks on 'Show results')

I would like to show ALL results when nothing is selected in the dropdown box.

I tried to add a * as a value to the dropdown box but this did not work.

Anyone got a clue on how to proceed with this one? ---
It's never too late to do the Right thing
 
Change the query language from "MATCHES" or "=" to "LIKE".
This will look for something that this.
SELECT music.song, music.artist, music.enteredby
FROM music WHERE (((music.song) Like '*love*'));

If the query field is blank, it will find everything in the base. WARNING... if the base is very large, it will shut down your system, trying to find everything. I suggest that you put a limit on how many items you want to put on a single page. That can be done with the query language also, using the wizard.

Hope that helps

Dick
drowland@ebasin.net

 
Dick,

thank you for your answer. Sometimes SQL knowledge comes handy.

Martijn

---
It's never too late to do the Right thing
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top