2006 Jan 24 7:18 PM
Dear friends ,
I have to duplicate a segment and all its sub custom segments. For ex E1EDK01 has custom segments ze1edk01 . I want to create an additional E1EDK01 segment which would also contain ze1edk01. Pls help .
Points will be awarded generously .
Thank you
Message was edited by: Alisha Albey
2006 Jan 24 7:47 PM
Could you please elaborate your requirement little more?
General Steps, Assuming that you want to insert the lines under same parent as E1EDK01
1) Loop through IDOC_DATA starting from E1EDK01 and traversing till the last child for that segment..
This can be achieved by checking that HIERLEVEL for subsequent records remain lesser than E1EDK01 heirlevel.
Copy all the records to internal table. Store the SY-TABIX for last record. Add +1 to these value.
Insert the new internal table records at the index value determined above.
If you are doing this within the user exit, there is no need to RENUMBER SEGMENTS.
But if you want to SAVE the IDOC data with new segments, You have to probably develop whole new logic that will renumber the segments.
Dear friends ,
I have to duplicate a segment and all its sub custom segments. For ex E1EDK01 has custom segments ze1edk01 . I want to create an additional E1EDK01 segment which would also contain ze1edk01. Pls help .
Points will be awarded generously .
Thank you
Message was edited by: Alisha Albey
2006 Jan 24 7:47 PM
Could you please elaborate your requirement little more?
General Steps, Assuming that you want to insert the lines under same parent as E1EDK01
1) Loop through IDOC_DATA starting from E1EDK01 and traversing till the last child for that segment..
This can be achieved by checking that HIERLEVEL for subsequent records remain lesser than E1EDK01 heirlevel.
Copy all the records to internal table. Store the SY-TABIX for last record. Add +1 to these value.
Insert the new internal table records at the index value determined above.
If you are doing this within the user exit, there is no need to RENUMBER SEGMENTS.
But if you want to SAVE the IDOC data with new segments, You have to probably develop whole new logic that will renumber the segments.
2006 Jan 24 7:55 PM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |