Count Expressions

I am running into a problem doing the simplest of things. I've a report that uses one table and has two groups that display appropriately. The groups are

Building
Person

The problem is that while using the built-in group count for person I can never get the real count.

There are 57 persons in my table and I get the following results:

PersonCount placed in Building Footer = 2
PersonCount placed in Person Footer = 1 ( even when there are more than one person in the group )
PersonCount placed in detail = 1

I've tried each setting in the properties regarding eval time and eval group over and over and over and I can not get a real count for the life of me.

It has to be something simple that I'm missing.
badir's picture
35
Joined: Sep 28 2006 - 8:16am
Last seen: 16 years 12 months ago

4 Answers:

Look at using the built in report variables. On the variable tab there should be a variable for each of your groups. It is in the format

Groupname_COUNT

for example if you called your group Person there will be a variable called

Person_COUNT

This value gives the total number of records in a group. It resets each time your group value changes.
svenn's picture
15112
Joined: Mar 19 2007 - 5:57am
Last seen: 16 years 6 months ago
I understand completely. The problem is that I am using Person_COUNT. It doesn't matter where I place that built-in. I always get a count less than 10.

Same with Building_COUNT. When I place the variable in the report ( no matter which band ) with the default properties, I get the wrong count.

What is actually being counted?
badir's picture
35
Joined: Sep 28 2006 - 8:16am
Last seen: 16 years 12 months ago
What is your expected output? Are you trying to get 57 persons as returned from the database?

If so, you must map the relevant DB field to the respective variable.

Eg: $V{Days}
Variable Expression : $F{Days}

I hope this helps you :)
samem_hr's picture
Joined: Aug 29 2007 - 2:51am
Last seen: 16 years 3 weeks ago
Try to set group evaluation time. As i see you have as evaluation time "Now".
yurish's picture
600
Joined: Aug 20 2007 - 12:26am
Last seen: 16 years 1 month ago
Feedback
randomness