First 50 queries setting not working

Gkirkup

Registered User.
Local time
Today, 09:51
Joined
Mar 6, 2007
Messages
628
I have a query which returns a calculated percent. I have ordered that in descending order, and now want to see the top 50. So (In Access 2010) I entered 50 into 'Return'. But it returns all of the records!
Is this because pct is a calculated field?
How can I correct this?
The SQL seems to be correct.
Robert

Code:
SELECT TOP 50 HeciFail1.POHECI, HeciFail1.POQTY, HeciFail1.FAILQTY, IIf(Nz([FAILQTY])>0,Round(100/([POQTY]/[FAILQTY]),0),0) AS PCT
FROM HeciFail1
ORDER BY IIf(Nz([FAILQTY])>0,Round(100/([POQTY]/[FAILQTY]),0),0) DESC;
 
If more than one record have the same value in the sort order ...
 

Users who are viewing this thread

Back
Top Bottom