Quantcast
Channel: SCN : All Content - User Interface Development in ABAP
Viewing all articles
Browse latest Browse all 540

LSMW With Multiple files and Multiple recordings

$
0
0

Hi Gurus,
  I need to create contract (VA41) through LSMW Batch Input Recording.

 

I have 3 input files. One for header, one for Item and one for billing plans. Each header will have multiple Line item and each Line item will have multiple billing plans.

 

The common field between Header and Item is KTEXT and between Item and Billing Plan is POSNR and MATNR.

 

I have created four recordings. 1. for header (VA41) 2. For first item (VA42) 3. For second item onwards (VA42) and 4. For billing Plan for items.

 

I have also created 3 source structure for header, Item and billing condition.

 

When i read data and display read data it is showing me prefect result as expected that is

 

Header1
Item1 for header1
Bill Plan1 for item1
Bill Plan2 for item1
Item2 for header1
Bill Plan1 for item2
Bill plan2 for item2
Header2
Item1 for header2
Bill Plan1 for item1
Bill Plan2 for item1
Item2 for header2
Bill Plan1 for item2
Bill plan2 for item2

 

But when i convert the data and see converted data it shows like this

Header1
Item1 for header1
Item2 for Header1
Bill Plan1 for item1
Bill Plan2 for item1
Bill Plan1 for item2
Bill plan2 for item2
Header2
Item1 for header2
Item2 for header2
Bill Plan1 for item1
Bill Plan2 for item1
Bill Plan1 for item2
Bill plan2 for item2

 

I think i have to write some code in Maintain field mapping and Conversion Rules step. But don't know what to write and what to do.

Can you please help..

I have attached test data for your reference so that you can go through and understand exactly what I need.

 

Thanks in Advance


Viewing all articles
Browse latest Browse all 540

Trending Articles