Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calculate Query

Status
Not open for further replies.

handlebars

Technical User
Feb 18, 2003
270
0
0
GB
I have a query that I cannot get to work that adds up line totals, then adds additional percentage charge, and subtracts a percentage discount from that total.

Should my solution be a query of a query of a query (seems messy) or can anyone suggest an appropriate way of doing this.

I have tried creating this as one query, but am getting errors.

Will post back the exact message if this is needed (do not have access to database at the moment).

Maybe a very obvious answer, but would be v useful!


Andrew
 
SELECT Field1, sum(field2) as A, sum(field3Percent) as B, sum("enter your expression here") as C
From YourTable
Group By Field1
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top