>I can't get this running total query to work.
>
>
>SELECT OrderId,
> UnitPrice,
> Quantity,
> UnitPrice * Quantity AS RowAmt,
> (SELECT SUM(UnitPrice * Quantity) AS RunningTot
> FROM [Order Details]
> WHERE OrderId = o.OrderId)
> FROM [Order Details] o
>
>
>I get "Incorrect syntax near the keyword 'FROM'." on the inner query.
>
>
You're just missing one parens. I corrected inline.
If it's not broken, fix it until it is.
My Blog