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

Combine multiple rows into one line 1

Status
Not open for further replies.
Feb 4, 2009
137
US
Please help, thanks.
I have a table results:

DocNo DocLine ItemID Code Value

733 1 28375 ExpDate 01/01/03
733 1 28375 MFGINV Organ
733 1 28375 UOI CY

733 2 97582 ExpDate 09/01/05
733 2 97582 UOI ea
733 2 97582 MFGINV Watson

I created a report using crystal report xi group by DocNo and group by DocLine

I have 3 formulas
@Expdate: If {table.Code} = "Expdate" then {table.Value}
@Mfg: If {table.Code} = "MFGINV" then {table.Value}
@UOI: If {table.Code} = "UOI" then {table.Value}

I placed all fields on the details
right now the results show:

DocNo: 733
DocLine ItemID Expdate MfgINV Code
1 28375 01/01/03
1 28375 Organ
1 28375 CY
2 97582 09/01/05
2 97582 EA
2 97582 watson


I want to get the results on my report such as:

DocNo: 733
DocLine ItemID Expdate MfgINV Code
1 28375 01/01/03 Organ CY
2 97582 09/01/05 Watson EA

please help, thank you very much for your time.
I'm very appreciated.


 
Insert a group on DocNo and then a second group on Docline and then right click on each formula in the detail section and insert a maximum at the group#2 level. Then suppress the details and group header. You can drag the docline and itemID fields into the group footer.

-LB
 
Thanks lbass for your help.
I'm not sure of what you mean on " insert a maximum at the group#2 level". However, this is what i did and look like it worked.

I supress the details and put every fields on the gf2 "docline".

I created 3 running total fileds...
for instance,
#Expdate:
Field to summarize: @ExpDate
Type of summary: maximum
Evaluate: for each record
Reset: on change of group (choose g#2 "table.DocLine")

do the same on the other 2...and put them all into the gf#2,

Is it OK if I do this way? look like it's still working right :)

Again, thanks for you help.
 
Lbass,
I found out how to insert maximum on each of those formulas. There has a button named "Insert Summary" so I clicked on it then
choose field to summarize and calculated the field equal "maximum" and place this field into the GF 2 "DocLine".
Thanks again,
report worked like a charm...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top