Quantcast
Viewing all articles
Browse latest Browse all 13329

Sum of Calculated field in a query

Hi all,

I have a query as follows:
Code:

SELECT da_ligne.RFQ_NATURE, sum(da_ligne.Total_Price) as Total FROM (SELECT da_ligne.C_DA, da_ligne.C_REF, da_ligne.RFQ_PRICE, da_ligne.RFQ_CURENC, da_ligne.RFQ_RATE, da_ligne.RFQ_TOOLS, da_ligne.RFQ_NATURE, ((([RFQ_PRICE]*[RFQ_RATE])*[Q_DEM])+([RFQ_TOOLS]*[RFQ_RATE])) AS Total_Price
Where da_ligne.C_DA="37744" and da_ligne.RFQ_NATURE="MG");

In the above query, Total_Price is a calculated field.
I want to get the total of the this calculated field as Total in the same query.

Any help will be helpful.

Thanks in advance.

Viewing all articles
Browse latest Browse all 13329

Trending Articles