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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query troubles . . help?!?

Status
Not open for further replies.

Brambojr

Technical User
Oct 26, 2000
73
US
I am putting together a small "application" to help us manage a particular kind of material in our distribution center.

To that end, I have a form to search records. Based on whether a combo or text box has a value it builds an SQL statement that is then sent to the subform. Then the subform is requeried.

Now I need one last detail that is frustrating me. I need to be able to query against descriptions, and how I want to handle that is by having a txtbox that when it has a value adds to the existing SQL.

My SQL that is built on the OnClick of a command button is based on another query that standardizes the display. The descriptions are all UCase$().

Here is the SQL:

SELECT [qryDept/Lic/Desc].License, [qryDept/Lic/Desc].Department, [qryDept/Lic/Desc].Group, [qryDept/Lic/Desc].PalletType, [qryDept/Lic/Desc].LOCATION, [qryDept/Lic/Desc].Description, [qryDept/Lic/Desc].RevisitDate FROM [qryDept/Lic/Desc] Where((([qryDept/Lic/Desc].Description) Like "*" TELXON "*")) ORDER BY [qryDept/Lic/Desc].Department, [qryDept/Lic/Desc].Group, [qryDept/Lic/Desc].PalletType, [qryDept/Lic/Desc].License;

The above is with all fields left blank except the description field, which was given the word "TELXON". This works beautifually for all other combo boxes.

What am I missing? I can't seem to figure this.

Can somebody shine a light on my oversight?

Thanks Brambojr
 
That should be:
Like "*TELXON*"
You've got too many quotes in there. Rick Sprague
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top