A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Sums by header value in report



 
 
Thread Tools Display Modes
  #1  
Old August 8th, 2007, 04:55 PM posted to microsoft.public.access.reports
[email protected]
external usenet poster
 
Posts: 32
Default Sums by header value in report

Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!

  #2  
Old August 8th, 2007, 06:08 PM posted to microsoft.public.access.reports
KARL DEWEY
external usenet poster
 
Posts: 10,767
Default Sums by header value in report

Try this in a textbox if Priority is a number field --
Sum(IIF([Priority] = 1, 1, 0))

Use this in a textbox if Priority is a text field --
Sum(IIF([Priority] = "1", 1, 0))

Repeat for priority 2 in another textbox.

--
KARL DEWEY
Build a little - Test a little


" wrote:

Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!


  #3  
Old August 8th, 2007, 06:22 PM posted to microsoft.public.access.reports
[email protected]
external usenet poster
 
Posts: 32
Default Sums by header value in report

On Aug 8, 12:08 pm, KARL DEWEY
wrote:
Try this in a textbox if Priority is a number field --
Sum(IIF([Priority] = 1, 1, 0))

Use this in a textbox if Priority is a text field --
Sum(IIF([Priority] = "1", 1, 0))

Repeat for priority 2 in another textbox.

--
KARL DEWEY
Build a little - Test a little



" wrote:
Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!- Hide quoted text -


- Show quoted text -

Thanks, Karl, for responding!
I wasn't clear about what I needed I think. I need the sum of the
costs for each priority, and the sum of the number of employees. So
what I need to sum for priorities 1, 2, and 3 is SumofCosts and
CountofEmployees. They are fields in the query on which the report is
based. Your advice did give me the sum of class occurences for each
priority, which is almost what I need.

  #4  
Old August 8th, 2007, 06:40 PM posted to microsoft.public.access.reports
KARL DEWEY
external usenet poster
 
Posts: 10,767
Default Sums by header value in report

Try using this ---
Sum(IIF([Priority] = 1, [SumofCosts], 0))

--
KARL DEWEY
Build a little - Test a little


" wrote:

On Aug 8, 12:08 pm, KARL DEWEY
wrote:
Try this in a textbox if Priority is a number field --
Sum(IIF([Priority] = 1, 1, 0))

Use this in a textbox if Priority is a text field --
Sum(IIF([Priority] = "1", 1, 0))

Repeat for priority 2 in another textbox.

--
KARL DEWEY
Build a little - Test a little



" wrote:
Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!- Hide quoted text -


- Show quoted text -

Thanks, Karl, for responding!
I wasn't clear about what I needed I think. I need the sum of the
costs for each priority, and the sum of the number of employees. So
what I need to sum for priorities 1, 2, and 3 is SumofCosts and
CountofEmployees. They are fields in the query on which the report is
based. Your advice did give me the sum of class occurences for each
priority, which is almost what I need.


  #5  
Old August 8th, 2007, 07:04 PM posted to microsoft.public.access.reports
[email protected]
external usenet poster
 
Posts: 32
Default Sums by header value in report

On Aug 8, 12:40 pm, KARL DEWEY
wrote:
Try using this ---
Sum(IIF([Priority] = 1, [SumofCosts], 0))

--
KARL DEWEY
Build a little - Test a little



" wrote:
On Aug 8, 12:08 pm, KARL DEWEY
wrote:
Try this in a textbox if Priority is a number field --
Sum(IIF([Priority] = 1, 1, 0))


Use this in a textbox if Priority is a text field --
Sum(IIF([Priority] = "1", 1, 0))


Repeat for priority 2 in another textbox.


--
KARL DEWEY
Build a little - Test a little


" wrote:
Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!- Hide quoted text -


- Show quoted text -

Thanks, Karl, for responding!
I wasn't clear about what I needed I think. I need the sum of the
costs for each priority, and the sum of the number of employees. So
what I need to sum for priorities 1, 2, and 3 is SumofCosts and
CountofEmployees. They are fields in the query on which the report is
based. Your advice did give me the sum of class occurences for each
priority, which is almost what I need.- Hide quoted text -


- Show quoted text -


Thanks, Karl! That works great! Just out of curiousity, is the way
that works like so:
=Sum(IIF(Criteria, value to summed for each record, don't know
what this is for)) ?

Thanks again for your help, it came just in time!

  #6  
Old August 8th, 2007, 08:04 PM posted to microsoft.public.access.reports
KARL DEWEY
external usenet poster
 
Posts: 10,767
Default Sums by header value in report


IIF(Criteria, what to present if criteria test true, what to present
if criteria test false)

--
KARL DEWEY
Build a little - Test a little


" wrote:

On Aug 8, 12:40 pm, KARL DEWEY
wrote:
Try using this ---
Sum(IIF([Priority] = 1, [SumofCosts], 0))

--
KARL DEWEY
Build a little - Test a little



" wrote:
On Aug 8, 12:08 pm, KARL DEWEY
wrote:
Try this in a textbox if Priority is a number field --
Sum(IIF([Priority] = 1, 1, 0))


Use this in a textbox if Priority is a text field --
Sum(IIF([Priority] = "1", 1, 0))


Repeat for priority 2 in another textbox.


--
KARL DEWEY
Build a little - Test a little


" wrote:
Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!- Hide quoted text -


- Show quoted text -
Thanks, Karl, for responding!
I wasn't clear about what I needed I think. I need the sum of the
costs for each priority, and the sum of the number of employees. So
what I need to sum for priorities 1, 2, and 3 is SumofCosts and
CountofEmployees. They are fields in the query on which the report is
based. Your advice did give me the sum of class occurences for each
priority, which is almost what I need.- Hide quoted text -


- Show quoted text -


Thanks, Karl! That works great! Just out of curiousity, is the way
that works like so:
=Sum(IIF(Criteria, value to summed for each record, don't know
what this is for)) ?

Thanks again for your help, it came just in time!


  #7  
Old August 8th, 2007, 08:18 PM posted to microsoft.public.access.reports
[email protected]
external usenet poster
 
Posts: 32
Default Sums by header value in report

On Aug 8, 2:04 pm, KARL DEWEY
wrote:
IIF(Criteria, what to present if criteria test true, what to present
if criteria test false)

--
KARL DEWEY
Build a little - Test a little



" wrote:
On Aug 8, 12:40 pm, KARL DEWEY
wrote:
Try using this ---
Sum(IIF([Priority] = 1, [SumofCosts], 0))


--
KARL DEWEY
Build a little - Test a little


" wrote:
On Aug 8, 12:08 pm, KARL DEWEY
wrote:
Try this in a textbox if Priority is a number field --
Sum(IIF([Priority] = 1, 1, 0))


Use this in a textbox if Priority is a text field --
Sum(IIF([Priority] = "1", 1, 0))


Repeat for priority 2 in another textbox.


--
KARL DEWEY
Build a little - Test a little


" wrote:
Hello all, I have a tricky summing problem for my report. It has the
fields Department, Priority, Category, Course, CountofEmployees, and
SumofCosts. It lists courses taken in each department, each with the
number of employees per class and total cost of sending that number of
employees to class. It is ordered first by Department, then by
Priority, then by Category, and it has to stay this way. I need sums
at the bottom of the whole report for each of the priorities, 1, 2,
and 3. Is there a way to say "sum all where priority=1" for a text
box control source or something?
This is very important, and anyone's help would be greatly appreciated!- Hide quoted text -


- Show quoted text -
Thanks, Karl, for responding!
I wasn't clear about what I needed I think. I need the sum of the
costs for each priority, and the sum of the number of employees. So
what I need to sum for priorities 1, 2, and 3 is SumofCosts and
CountofEmployees. They are fields in the query on which the report is
based. Your advice did give me the sum of class occurences for each
priority, which is almost what I need.- Hide quoted text -


- Show quoted text -


Thanks, Karl! That works great! Just out of curiousity, is the way
that works like so:
=Sum(IIF(Criteria, value to summed for each record, don't know
what this is for)) ?


Thanks again for your help, it came just in time!- Hide quoted text -


- Show quoted text -

Ah, got it. Thanks!

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 07:20 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.