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

sql with ROWNUM criteria 1

Status
Not open for further replies.

dbero

Technical User
Joined
Mar 31, 2005
Messages
109
Location
US
I am unable to get the WHERE ROWNUM<=10 criteria to work.

SELECT QRYMaster.Status, QRYMaster.Region
FROM QRYMaster
WHERE ROWNUM<=10;

Can someone identify the problem?

Thank you
 
An error message would help.

Is ROWNUM in the output for QRYMaster?

Is ROWNUM a number?

Or are you trying something from SQL from another language and you want the top 10 rows?

Code:
SELECT TOP 10 QRYMaster.Status, QRYMaster.Region
FROM QRYMaster
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top