I have ALV layouts saved in a system where data was present but it is not possible to transport those variants from the testing system (system where test data is present). So I have to create same layout variants in development system which is not possible due to lack of test data. Please provide a way to achieve this.
3 Answers
As far as I know there's no standard way to do this. If there's not many variants I suggest you to copy brainless. (I think you can reproduce every layout options without any data) For many variants to copy you can write a program to upload to the DEV system for time-saving.
Please be careful with this because it modifies standard tables! The system version, ALV structure should be identical and previous records of variants should not be present, otherwise the result is unexpected!
SAP stores ALV variants in tables LTDX and LTDXT. LTDX contains the variant properties in RAW format. You can download the raw data with SE16 to a tab delimited file from the test system and upload with a developed program to the developer system.
Don't use this program to upload to productive or other systems, go with transporting, use program
RKKBALVI
. Always try the results after uploading to developer, always!
The LTDX-RELID is always 'LT' and the LTDX-REPORT is the program's name you are interested in. Don't forget to edit the file to suit your needs (for example remove the headers and mandant if needed). When you check the downloaded file you can see the raw hex dump of the CLUSTD field.
The concept comes from the idea that you can move HEX content easily from a string type to a binary type field. See this example taken from a little example program in debugger. ('41424150' in HEX = 'ABAP' in ASCII)
So you have to develop a program to upload the contents of the downloaded files to LTDX and LTDXT with cl_gui_frontend_services=>gui_upload
but defining the import structures's CLUSTD field as string first. When you imported the data you can move the contents to the real LTDX structure and update the table.

- 1,271
- 1
- 9
- 12
The question of layout transportation is reviewed rather clearly in note 551178 aka FAQ: ALV layout.
Yes, you can transport ALV layouts to another system unless they are user-specific. This is done in ALV layout administration via Customizing request:
Main Menu -> Settings -> Layout -> Administration
User-specific layouts are not transportable, only all-users layouts have this feature.

- 10,355
- 10
- 52
- 90
-
I think the OP cannot transport because in testing it's not possible to create and release a transport request. @Rajasekharreddy Panditi? – szako Apr 08 '17 at 08:27
-
It depends on concrete SAP-landscape and OP authorizations, and this is out of the scope of the question. – Suncatcher Apr 08 '17 at 10:04
-
1Yes it is not possible to create and release a transport request in test environment and that's where we struck at. Apart from maintaining a test data in dev environment I am expecting an alternative to achieve this. Thanks- – Rajasekharreddy Panditi Apr 10 '17 at 04:56
-
I doubt you'll succeed with finding alternative ways. – Suncatcher Apr 10 '17 at 05:46
-
I tried displaying the ALV without any data by commenting the validations in my code. In short I simply displayed the ALV header and saved the header. I am afraid that If that is going to work or not because it goes into production. Any suggestions? – Rajasekharreddy Panditi Apr 13 '17 at 01:53
You can also use program RKKBALVI to copy layouts between clients. For example, we have to develop & configure in client 100 and ALL transports come from 100, but test in client 600.
So, develop the report, test it in 600 and create layout in 600. Then, in 100, run RKKBALVI, enter the program name and execute. From there (list will likely be empty), use menu option Environment > Import layout. It will ask for the Source Client, enter your test client. Select the layouts you want to copy then use the Import icon (or F8).
This will copy the layouts to your client, in our case 100. Then I can use this same program to add them to a transport. So, I can now release my transports from 100 to transport both the report and the layout.

- 11
- 1