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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tables and totaling fields

Status
Not open for further replies.

Danielle17

Technical User
Apr 17, 2001
102
US
Is it possible to total 4 fields in a query? I've been trying everything. What does the expression have to look like for the column that will add the other 4 columns? I have tried the following:

Sum([LodgingCost]+[MealsCost]+[GasCost]+[MiscCost]) But I get the error - Extra paranthesis. I've checked and double-checked and cannot find a extra one.

Sum([LodgingCost]&[MealsCost]&[GasCost]&[MiscCost])

What am I doing wrong on these?

 
Danielle:

If you are doing this in a query, you don't want to use the Sum function.

Your expression should look like this

SomeName: [LodgingCost]+[MealsCost]+[GasCost]+[MiscCost])

If you don't name the field (SomeName) you will get something like Expr1 as a column header.

Hope this helps.
Larry De Laruelle
larry1de@yahoo.com

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top