G
Guest
This is a school asmt where I need to pull the total > $10,000 using SQL, not
the design view. I tried the below, but it asks for the parameter value of
OrderTotal, then comes up blank.
SELECT OrderID, (UnitPrice * Quantity) - (UnitPrice*Quantity*Discount) AS
OrderTotal
FROM [Order Details]
WHERE OrderTotal > 10000;
By using the Design view, I see that the below statement works, but I'm
hoping someone can explain why my 1st attempt does not since I'm not supposed
to be using the Design view.
SELECT [Order Details].OrderID,
(UnitPrice*Quantity)-(UnitPrice*Quantity*Discount) AS OrderTotal
FROM [Order Details]
WHERE ((((UnitPrice*Quantity)-(UnitPrice*Quantity*Discount))>10000));
the design view. I tried the below, but it asks for the parameter value of
OrderTotal, then comes up blank.
SELECT OrderID, (UnitPrice * Quantity) - (UnitPrice*Quantity*Discount) AS
OrderTotal
FROM [Order Details]
WHERE OrderTotal > 10000;
By using the Design view, I see that the below statement works, but I'm
hoping someone can explain why my 1st attempt does not since I'm not supposed
to be using the Design view.
SELECT [Order Details].OrderID,
(UnitPrice*Quantity)-(UnitPrice*Quantity*Discount) AS OrderTotal
FROM [Order Details]
WHERE ((((UnitPrice*Quantity)-(UnitPrice*Quantity*Discount))>10000));