Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Counting cross-tab rows

Status
Not open for further replies.

gav12345

Programmer
Dec 4, 2003
198
GB
Hi,

Once again I turn to tek-tips for help. Using CR10, I need to add a database field in the page footer of a report, based on the value in one of the rows in an inserted crosstab. The structure of the cross-tab is broadly as follows:

An. Group An. No COLUMN DATA
1 13
9
6
24
31
32

2 12
11
26
17
19
3

3 10
16
7
2
4
20

What I'm trying to do is only display the database field relevant to the 'An Group' on a particular page of the report. - So if only 'An Group' 1 and 2 appeared on page 1 of the report, I would only want to display data relevant to those groups in the page footer for that page.

I've tried counting the animal groups then writing a formula on that basis, but have had problems trying to count the number of cross-tab groups on a single page, as opposed to the whole report.

Hope this is reasonably clear - as always, many thanks for any suggestions.

Gavin
 
I recognize this crosstab from a previous thread, where you had different issues requiring either placing the crosstab in the animal group group header or using a manual crosstab. Please let us know whether you are using an inserted or a manual crosstab, and if inserted, where it is located (what section).

-LB
 
lbass, yes, I considered mentioning the earlier issue. - For various reasons I've put that to one side for just now (essentially need to get something out quite soon, and with my limited Crystal skills it was taking too long).

The cross-tab is therefore still a standard (inserted) crosstab. It's inserted in a group footer section of a group named 'Time Point'.

I would like to go into more detail on the report but this could get very lengthy. Please let me know if you do need more info.

Many thanks, Gavin
 
So the crosstab in a particular group footer crosses multiple pages? Or do one or more footer sections (and therefore crosstabs) appear per page?

-LB
 
lb - The crosstab in a particular group footer crosses multiple pages. I only want to display a particular database field in the page footer, if the animal group to which it is relevant appears on that page. Gavin
 
I don't believe you will be able to do that with your current design, since the crosstab is an object and there isn't a way to define what appears on one page of the report. The only option that I think would work relates back to my suggestion in the previous thread. You could place the crosstab in a group footer based on a group on animal group. Then you would be able to use variables to capture the groups that appear on one page--but this is based on using the report groups, not the corresponding crosstab groups.

-LB
 
Thanks again lbass. I'll try the manual cross-tab option when I have time; the users will have to make do in the meantime. Gavin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top