Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

merging two alvs

Former Member
0 Kudos

hi, i have a report(call z1) which uses alv to display certain data. there is a transaction(call t1) using z1. there is another transaction(call t2) which runs a report(call z2) again containing an alv to display some other data. the requirement is that t1 needs to be modified such that it will display some extra columns which need to be obtained from t2. so basically the alv of z1 will be enhanced with a subset of columns of the alv from z2. ofcourse a subset of columns of alv from z1 will form the key to select the corresponding rows of data of alv from z2. there will be a relationship, much like inner join or something on sql.

on what level do i need to work? is there an easy way to accomplish the task? any suggestions are appreciated, thanks.

Message was edited by:

Selcuk Cihan

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Simplest option is to just add the extra columns to the internal table, field catalog and select logic in the first report. You can use report z2 as a source for the required code and just copy it, or you could build a shared include with forms or a function module or class that builds the data required, and then call the common code from both reports.

Trying to link the two reports another way would mean that changes to one report would break the other one which complicates ongoing support.

Andrew

2 REPLIES 2

Former Member
0 Kudos

Simplest option is to just add the extra columns to the internal table, field catalog and select logic in the first report. You can use report z2 as a source for the required code and just copy it, or you could build a shared include with forms or a function module or class that builds the data required, and then call the common code from both reports.

Trying to link the two reports another way would mean that changes to one report would break the other one which complicates ongoing support.

Andrew

0 Kudos

thanks andrew, i followed your suggestion and added the required columns to the internal table and used the source code of z2 for data retrieval. it was really simple, i had been exaggerating the situation.