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

CONCATENATE GROUP RECORDS

Status
Not open for further replies.

Kim296

MIS
Aug 24, 2012
98
US
I found two formula's that allow you to concatenate detail records and I tried using it on group records and it works... Except it doesn't reset for new records; it just continues for ALL records. When using this to concatenate group records, does anyone know how I can reset it to start over on each group change?

//@Concate. placed in the group header
WHILEPRINTINGRECORDS;
STRINGVAR CONCAT;
CONCAT:= CONCAT + TRIM (TOTEXT(({jinames.name_id})))+" , "

//concatdisplay. placed in the the group footer
WHILEPRINTINGRECORDS;
STRINGVAR CONCAT;
LEFT(CONCAT,LENGTH(CONCAT)-2)

Thanks for any and all help.
Kim
 
Wow. I figure out my own problem. To concatenate group records, this is what I did and it works.

//@reset, placed in the main group header
stringvar CONCAT :="";
WhilePrintingRecords;
CONCAT

//@Concate. placed in the secondary group header
WHILEPRINTINGRECORDS;
STRINGVAR CONCAT;
CONCAT:= CONCAT + TRIM (TOTEXT(({table.field})))+" , "

//concatdisplay. placed in the the group footer
WHILEPRINTINGRECORDS;
STRINGVAR CONCAT;
LEFT(CONCAT,LENGTH(CONCAT)-2)

Hope this helps someone else.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top