|
-
Query question
If I had these items to search:
Year, Make, Model, Style, Color, Price, Dealer
And I wanted to query any combination of and only of including skipping one of:
Year, Make, Model
The way I have it now is:
SELECT Year, Make, Model, Style, Color, Special, Price, Dealer FROM Pinellas WHERE Year = '%%Year%%' OR Make = '%%Make%%' OR Model = '%%Model%%'
This works fine untill I skip for example YEAR then it say no records found. I guess the questions is what would be a wildcard for YEAR to return all if NULL?
This is in Frontpage/Access97
Thanks,
Luke Barnes
[email protected]
-
Query question (reply)
you could put inside of your select...(iif(isnull(year),"",'%%Year% %' ) or (iif(isnull(...etc for all of them
this will give an empty string value in place of null... should work...have used before in similar type select statements....
good luck....
kim
------------
Luke Barnes at 5/26/99 9:45:34 AM
If I had these items to search:
Year, Make, Model, Style, Color, Price, Dealer
And I wanted to query any combination of and only of including skipping one of:
Year, Make, Model
The way I have it now is:
SELECT Year, Make, Model, Style, Color, Special, Price, Dealer FROM Pinellas WHERE Year = '%%Year%%' OR Make = '%%Make%%' OR Model = '%%Model%%'
This works fine untill I skip for example YEAR then it say no records found. I guess the questions is what would be a wildcard for YEAR to return all if NULL?
This is in Frontpage/Access97
Thanks,
Luke Barnes
[email protected]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|