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

Dumb Order By Question 1

Status
Not open for further replies.

WB786

MIS
Mar 14, 2002
610
This is what I have:

strSQL = "SELECT * FROM tblItems WHERE [Active]=true and [ClassNumber]= '" & Request.querystring("Id") & " ORDER BY [ItemName]'"

But my items are not coming up and if I remove ORDER BY then the items show on the page. But I need to have this ORDER BY ItemName.

Thanks in advance,

:)WB
 
You had an apostrophe in the wrong place.

Code:
strSQL = "SELECT * FROM tblItems WHERE [Active]=true and [ClassNumber]= '" & Request.querystring("Id") & "[!]'[/!] ORDER BY [ItemName]"

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
WORKED!!! THANK YOU FOR THE QUICK RESPONSE. I need to get my eyes checked again!!!

:)WB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top