how do you add columns in a query?

ilkvarr

New Member
Joined
Sep 7, 2015
Messages
2
how do i add two columns together in a access query?


also as a side question, i've been asked to make an access database to log all the invoices we send out each month. were a community transport charity, and all of our invoices are generated by another program, using a mail merge, from a .csv which our booking program creates. i can import the .csv data into an access table, and it has a months invoices on it, but i want to be able to add the total for each person up across 1 or more months, as we don't send invoices out, until the total reaches £15

so what i want it to do is add up the totals fairs for each person across two months, all the fields, and most of the names are the same.

is there any easy way to do that? (i want to keep each months invoices in a separate table)
 

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.
how do i add two columns together in a access query?
Don't know which version you're using, so here's one way that should work.
If you need to SUM columns in a query, enter something like GrandTotal: CInt(Nz([fld1],0)) + CInt(Nz([fld2],0))... in the field header row of the query design grid, unless you are POSITIVE that no rows can be Null and the values are numeric only in all of the fields you want to sum. In that case, you could simply use [fld1]+[fld2)...
i want to be able to add the total for each person up across 1 or more months, as we don't send invoices out, until the total reaches £15
Create a totals query (assuming you wish to perform a calculation on one or more fields for a group of records, such as being based on an individual). Group By "person" and if you're adding fields (columns) for each person, use one of the above expressions in a calculated field but put >=15 as criteria.
Create a Select query first to see that you're getting something that looks right (without totals) then convert that to a Totals query. Of course, this is where you set the criteria for x # of months or some date span, as well.
(i want to keep each months invoices in a separate table)
If you need to put the results in another table, I think you can use a totals query as the basis for an append query that will add these records to a table. I don't believe you can use a totals query directly to append records.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,221,845
Messages
6,162,350
Members
451,760
Latest member
samue Thon Ajaladin

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top