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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Custom Group from Formula

Status
Not open for further replies.

befine

Instructor
Apr 18, 2002
79
US
Is there a way to create a group based on a formula that will give me exactly 5 groups? I thought I had read something like that on this ng, but can’t seem to find it.

The database isn’t setup to create the kind of groups ‘they’ want so I’m trying to force CR to give me a set number of groups and I’ll manipulate the data within each group based on the group numbers.

I know this sounds strange, but then some of these reports have had up to 50,000 pages and this might be an easier one. :)

Thanks in Advance
 
5 groups based on what? Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
Sorry it wasn't clear.
I need 5 groups based on a formula that just counts from 1 to 5. I can't use any of the fields in the data source, so I'm hoping there is a way to force the report to have 5 groups.

I hope this doesn't muddle it up any more.

Thanks
 
Do you just mean you want to randomly assign each record to one of 5 equal sized groups? Crystal can't do that with true groups, because it would have to group before it could do the counting.

Tell us how you want to use the groups once you have them. Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
Thanks for the quick response. I’ve been teaching CR for a while, but this project is driving me batty.

Here’s what’s happening. I have 2 sub reports. Sub1 in DetailsA and Sub2 in DetailsB. Each one has 5 pages. Normally they print out as:
Sub1 pg 1-5
Sub2 pg 1-5

What I’m trying to get to is:
Sub1 pg 1
Sub2 pg 1
Sub1 pg 2
Sub2 pg 2
Etc
Sub1 pg5
Sub2 pg5

I thought that by creating a fake group based on the numbers 1-5, I could control the printing of each sub. I could create a small table in the db with the number I need (in this case 5). If that’s not possible, I’ll have to go back to the drawing board and get CR to jump thu a different hoop.

Thanks
 
There is no way to group based on the page number of the record.

Are there always exactly 5 pages of data?
Are the records sorted in any order?

You could try suppressing records based on the record number range for each page. You would have to know how many records fit on each page.
Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top