Regarding a Query in Northwind Sample DB

Carol Frangipane

Registered User.
Local time
Today, 14:32
Joined
Jul 11, 2007
Messages
19
In the Northwind DB, there is a query of the "Ten Most Expensive Products"

After looking at it, I can't figure out where or how it knows to only pull the 10 highest price products. It's probably right in front of my nose...but it's making me crazy!

Thanks for any replies...
 
The query just sorts the UnitPrice in descending order and pulls the top 10 records.

SELECT TOP 10 Products.ProductName AS TenMostExpensiveProducts, Products.UnitPrice
FROM Products
ORDER BY Products.UnitPrice DESC;
.
 
Northwind Query

Please forgive me...I'm a beginner...

How do you locate that code in the query? I don't see it in the query window.
 
The code is called a SQL statement.

When you open the query in Design View, you can easily switch to SQL View e.g. by selecting menu View, SQL View.
.
 
Northwind Query...Thank you!

I never would've found that SQL window! You guys are going to make me so smart. I love this forum. Wish I had found it two years ago!

Thanks again...
Carol
 

Users who are viewing this thread

Back
Top Bottom