Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1399
  • Last Modified:

Access 2003 - Report and subtotals of report

I have an Access 2003 database that I want a report to sub total by month and within that month subtotal certain parts

This is how the table set up
 These are the fiels  - Month, Plan, Amount($amount)
Want the report to show

Jan 2007
      Plan 1      $5,000
     Plan 3 + 4        7,000
    Plan 2               2,000
Month Total       14,000

Feb  2007
      Plan 1      $5,000
     Plan 3 + 4        7,000
    Plan 2               2,000
Month Total       14,000

Is there a way to pull certain plans out as a subtotal and then add them all together
0
Pdeters
Asked:
Pdeters
  • 6
  • 2
1 Solution
 
PdetersAuthor Commented:
All the plans are in one field
0
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
>Is there a way to pull certain plans out as a subtotal and then add them all together
afaik no.  I recommend doing this in the query that serves as your report's RecordSource, and then just adding/summing that field separately.
0
 
PdetersAuthor Commented:
How would I go about doing that.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 
PdetersAuthor Commented:
I have in the query
Month, Plan, Amount($amount
I do I pull out the sepate plans to sum them

0
 
Jim HornMicrosoft SQL Server Developer, Architect, and AuthorCommented:
I think you'll have to create a separate query that does the sum, but with WHERE PLAN NOT IN(3, 4)  'or something like that

Then, create a third query which relates your original one and this one...
0
 
PdetersAuthor Commented:
ok - so for all the plans i would create a separate query and then create one that links them all together
0
 
PdetersAuthor Commented:
How would I create that 3rd query to link them ?
0
 
PdetersAuthor Commented:
Thank you - I got it figured out. I had to do a couple of queries and then put them together in another query and it work. Thanks for sending me in the right direction!
0

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

  • 6
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now