473,386 Members | 2,042 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Sum ?

I am completly new to Access. So Please bear with me
I have a Data base with 5 Currency Fields in my Main table.

I can get totals From each one separtly, however, I can not get All 5 to total for a grand total.
Example Cost 1 $100..00
Example Cost 2 $100..00
Example Cost 3 $100..00
Example Cost 4 $100..00
Example Cost 5 $100..00

Total.........Nothing or an Error...
Been tring both query or report.....I ultimatley need it in a report by a date spread...
Been at this for two weeks now with searching and reading help, but just can not get this to work. Thanks in Advance.
Sep 5 '06 #1
6 2111
MMcCarthy
14,534 Expert Mod 8TB
In query create a new column

TotalCost: [ExampleCost1] + [ExampleCost2] + [ExampleCost3] + [ExampleCost4] + [ExampleCost5]
You can then sum this field to get the total overall cost.

I am completly new to Access. So Please bear with me
I have a Data base with 5 Currency Fields in my Main table.

I can get totals From each one separtly, however, I can not get All 5 to total for a grand total.
Example Cost 1 $100..00
Example Cost 2 $100..00
Example Cost 3 $100..00
Example Cost 4 $100..00
Example Cost 5 $100..00

Total.........Nothing or an Error...
Been tring both query or report.....I ultimatley need it in a report by a date spread...
Been at this for two weeks now with searching and reading help, but just can not get this to work. Thanks in Advance.
Sep 5 '06 #2
comteck
179 100+
Create your query, and make it a totals query by clicking on the appropriate icon on the toolbar (It'll say "Totals" when you move the mouse over the top of it). A new field appears called Total. Keep "Group By" in all these fields, except the one that you want to do the Sum. On that one, click the pull down menu and choose "Sum". This is the field that will have all your fields added together:
TotalCost: ([Cost1]+[Cost2]+[Cost3]+[Cost4]+[Cost5])

Also, since you want to select a certain date range, I'm assuming you have a date field in your table. Make sure it's selected in the query, and in the criteria field (Under the Date field), type the following:

Between [Enter Start Date] and [Enter End Date]

This will prompt you for your Start and End Dates.

Hope this helps.
comteck
Sep 5 '06 #3
Thanks for the replys I am still doing something wrong here.
here is what the query looks like in Design View no error but no total either.

Field: TotalCost: (formula) Cost1 Cost2 Cost3 Cost4 Cost5

Table: Tool Damage Tool Damage Tool Damage Tool Damage Tool Damage

Total:Expressions(changes itself) the remainder is group by

All check boxes are checked.....

This is killing me I know I am getting closer......
Sep 5 '06 #4
No More Ideas?...LOL....
Sep 5 '06 #5
MMcCarthy
14,534 Expert Mod 8TB
Go to the Queries SQL view and copy and paste the code here. I can't follow what you've written.



No More Ideas?...LOL....
Sep 5 '06 #6
Thanks I well try that....I followed the previous directions and posted the fields I had in query in design view......Sorry to confuse you
Sep 5 '06 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: William C. White | last post by:
Does anyone know of a way to use PHP /w Authorize.net AIM without using cURL? Our website is hosted on a shared drive and the webhost company doesn't installed additional software (such as cURL)...
2
by: Albert Ahtenberg | last post by:
Hello, I don't know if it is only me but I was sure that header("Location:url") redirects the browser instantly to URL, or at least stops the execution of the code. But appearantely it continues...
3
by: James | last post by:
Hi, I have a form with 2 fields. 'A' 'B' The user completes one of the fields and the form is submitted. On the results page I want to run a query, but this will change subject to which...
0
by: Ollivier Robert | last post by:
Hello, I'm trying to link PHP with Oracle 9.2.0/OCI8 with gcc 3.2.3 on a Solaris9 system. The link succeeds but everytime I try to run php, I get a SEGV from inside the libcnltsh.so library. ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.