How to select top 10 in Access query?

select top 10 Name, Price
from MyTable
order by Price desc

Updated: @Fionnuala pointed out that:

“Access SQL selects matches, so it will select all items with the
same highest prices, even if this includes more than 10 records. The
work-around is to order by price and a unique field (column).”

So, if you have a unique product code column, add like so:

select top 10 Name, Price
from MyTable
order by Price desc, UniqueProductCode desc

Leave a Comment