|
-
Nov 19th, 2002, 11:51 AM
#1
Thread Starter
Lively Member
Check if current field is in last line of group
In Crystal 8.5. Is it possible for me to check if a certain detail field is in the the last line of a group? Thanks in advance.
Jack
-
Nov 19th, 2002, 12:04 PM
#2
Hyperactive Member
can u b a li'l bit more clear
-
Nov 19th, 2002, 12:38 PM
#3
Thread Starter
Lively Member
OK, here goes:
In essense I am trying to eliminate the use of a subreport.
The report's main data source is comprised of a Physician_Names table. Each physician can have 1 or more addresses which are located in a Physican_Addresses table linked by a PhysID. Finally I have a table that contains the amount of prescriptions written per product along with the PhysID of the prescribing physician. Each product is in its own line.
I have 2 groups in the report. The outer group is a territory number. For this question I don't think its important.
The second group is the PhysID of the doctor. In its footer I have a subreport containing all my Prescription data for each physician linked by the PhysID which for perfomance reasons I would like to eliminate.
In the detail section I have all the address data for each doctor (one line per address).
I was hoping to split the detail section into 2 parts, with DetailA containing address lines and DetailB containing prescription count lines. I would then use a formula to suppress DetailB until the last address was printed. So what I need is a formula or way to check in a variable whether or not the last DetailA line was printed for each Physician group.
Hope all this helps.
Regards,
Jack Vinitsky
-
Nov 19th, 2002, 01:23 PM
#4
Hyperactive Member
Any group or Details section can be spiltted into multiple sections.. by clicking 'Insert Section Below' from the popup menu which u get by right clicking the group / details section.
and Second section starts only after first section is printed
hope this wht u wanted !!
-
Nov 19th, 2002, 01:49 PM
#5
Thread Starter
Lively Member
Thanks for the response. Only problem with what you suggest is that the prescription (DetailB) data will print a set of records for every address located in DetailA where I would only need them to come up once after all the address would be printed.
If I can get the right formula to return whether the current record in DetailA is the last of the group, I can then suppress DetailB until the very end of the group (after the last Address in Detail A is printed).
-Jack
-
Nov 19th, 2002, 02:04 PM
#6
Hyperactive Member
Check Suppress if duplicated in 'Format field' for the records which are duplicated.
Or
u can include Prescriptions table in the main report and place the fields in the physId group footer
or
if u still wanted to use a formula .. u hav some conditions ( i dont remember properly.. and i dont hav cry rep on my sys now) for evaluating the expression in the formula , which will b useful to u
-
Nov 19th, 2002, 02:38 PM
#7
Thread Starter
Lively Member
Suppressing if duplicate won't work because each prescription detail line exists for each product of which currently there are 2, thus the rows alternate are not duplicates.
Placing them in the group footer would only get me the first detail item (product) and not the second.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|