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

Random Problem

Status
Not open for further replies.

scott1971

Technical User
Apr 20, 2005
125
0
0
EU
thread767-1493843

Sorry to ask two in the one day but I'm struggling with this one. I have 4 GH's and GH3 holds the detail I want the random sample for with GH 4 having the detail.

I have my formula and have placed Dgilz formula in the suppression box but it's suppressing all of my GH3. Can anyone tell me where I am going wrong with this one?

Much appreciated

Scott
 
I don't think it has to be this complicated, but I'm unclear--are you looking for a set of random GH3 records within each Group #2? Or random GH4 records within each Group #3? How many?

-LB
 
lbass, What I have is Claim Numbers at GH3 and that is what I need the random sample of. That sits under GH1 which is a provider Type and GH2 which is a Claim Type. I'm trying to get a sample of 50 Claims from GH3 that relate to GH2. The problem is that each claim has various details attached so it could be 1 - 100 lines of data in GH4 that I need.
 
You can do this by creating a formula {@rnd}:

rnd()

Place this in your detail section and insert a maximum on it at the GH3 level. Then go to report->group sort->topN: 50 and select maximum of {@rnd} as your group sort field.

This will give the top 50 GH3 within each Group #2. But please note that everytime you refresh the report the random groups will be different.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top