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

Displaying report in single line format

Status
Not open for further replies.

m3gd04

Technical User
Sep 17, 2004
17
US
Hello group,

Hopefully not to difficult of a question. I was hoping someone could show me in Bus Obj how to convert multiple lines of data (belonging to same record) and displaying it on one line only. Right now, I have a simple query that shows:

Case# Surgeon Procedure DelayReason
123 ASmith Hernia came late
123 ASmith Lap Chole came late


My 3rd field "Procedure" shows 2 different types which rolled over to next line item.

How can I get this to show on one line.

Any assistance would be great :)

 
Insert a group on case # and then create three formulas:

//{@reset} to be placed in the group header and suppressed:
whileprintingrecords;
stringvar proc;
if not inrepeatedgroupheader then
proc := "";

//{@accum} to be placed in the detail section and suppressed:
whileprintingrecords;
stringvar proc;
proc := proc + {table.procedure}+", ";

//{@display} to be placed in the group footer:
whileprintingrecords;
stringvar proc;
if len(proc)>2 then
left(proc,len(proc)-2)

Drag your other fields into the group footer and add this formula instead of the procedure field. This assumes that the only field that might have more than one distinct value is the procedure field. Then suppress the group header and detail sections.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top