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

Combine multiple records into field, then group

Status
Not open for further replies.

Drus

Technical User
Jan 29, 2002
43
0
0
US
I want to combine extended description fields into one field that shows at the record level. For example...

Table1:Inventory Item
Table2:Extended description on inventory items

Table1.ItemNo Table2.ExtDesc Table2.Sequence
Details >
Record #1 A100ZX Interface, tabl 001
Record #2 A100ZX e mount. 002

*****************************

I want to have the following (then group by ExtDesc)...

Table1.ItemNo Table2.ExtDesc Table2.Sequence
Details >
Record #1 A100ZX Interface, table mount. 001
Record #2 A100ZX Interface, table mount. 002


&ru
 
You may have missed the subtlety here. Or maybe I am missing the simplicity (but I doubt it). By adding the two fields together, here is the result I get...

Table1.ItemNo Table2.ExtDesc Table2.Sequence
Details >
Record #1 A100ZX Interface, tabl 001
Record #2 A100ZX e mount. 002

*****************************

The reason for this is that Table1 to Table2 is a one-to-many relationship in a flat file database. So I don't know that it can be done unless the data were exported to Access first. Your thoughts?




&ru
 
Try grouping on {table1.itemno} and then create three formulas:

//{@reset} for the group header:
whileprintingrecords;
stringvar x := "";

//{@accum} for the detail section:
whileprintingrecords;
stringvar x := x + {table2.extdesc};

//{@display} for the group footer:
whileprintingrecords;
stringvar x;

Then drag the groupname into the group footer next to {@display} and suppress the details and group header sections. I'm assuming you only really want the one line.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top