Why ABAP Table Controls Are Evil

By | August 29, 2013 | Table Maintenance | 5,020 | 1

Table Controls are not that much flexible enough. On top of that it would also add more issues in the mix based on the way how they are defined.

Recent Issue

I have been working on an upgrade project recently where the client is upgrading to EHP6. Upgrade is going in phase with having one system in original release to compare apple-to-apple.

One of the user reported an issue with the table maintenance for the one the standard view. The view was not modified by the client. He couldn’t see all the columns in upgraded system which he can see in non-upgraded system.

When there is an upgrade majority of time the issue would be encountered due to some of the code changes introduced as part of the upgrade. You would look for the OSS note and see if any of the valid OSS note is missing which could fix your issue. I did found out that the program LSVIMOXX have few of the PBO modules which are being called before the screen is displayed. So, I did the same thing and looked for OSS notes. I found a note. But the note is not valid the latest release. What I was expecting that the code in the upgraded system would match with last correction instruction – as there is no issue in latest release and latest support pack carries the instructions. But the code doesn’t match with the correction instruction’s code from “Insert” section.

That made me jumped out of chair and said, SAP has changed the code and it is missing the same code in the program. We raised an OSS message with SAP. SAP came back with the point that the screen is customer generated in the standard Function group. The table maintenance is using the screen 9090 in the std group vs screen 160 and 161 delivered by SAP. So, SAP won’t support on this.

Only option we had now is to fix the program LSVIMOXX by ourselves. We started doing it and it is not getting any effect. Even after the change in the code, we still see only 2 columns, not all 16 columns. We tried to change another PBO to make all the columns ACTIVE all the time for testing to see if the columns are coming up or not. But they didn’t. I even tried to change few of the fields position on generated screen but it didn’t show up all the columns.

Root Cause

After so many rounds of fix and test, it made me think that I’m missing an important point. I checked the table control definition.

The existing definition:

CONTROLS: TCTRL_V_001W_IV
TYPE TABLEVIEW USING SCREEN '0160'.
 

It should be:

CONTROLS: TCTRL_V_001W_IV
TYPE TABLEVIEW USING SCREEN '9090'.

Since screen 160 – the standard overview screen – contains only two columns, the table maintenance displays only those two columns. That’s the reason, all my tries to display the other columns in PBO, were going in vein.

WWW – What Went Wrong

You might think why the screen reference was changed in upgrade.Std SAP delivers the table maintenance for the view in two steps: Overview Screen using screen 160 and Detail screen using 161. Somebody from client side had generated another screen 9090 as the detail only – in order to display all the values in single table control.

Upgrade came in and it replaced the code which was using 9090 with 0160. You would ask, why they are not registered in SPAU? For those who are not familiar with SPAU – it is a tool to accept the customer modification and preserve them in the upgraded environment. Since the program which contains the definition code, is auto generated and forbidden for changes – the program never showed up in the SPAU. Screen 9090 also didn’t came up as it is custom generated, not std delivered and customer changed.

Lessons Learned

Table control definition is being derived from the screen in its definition. If you have same name of table control in two screens with different number of columns, GUI would always render the table control with reference to the screen definition. No matter what screen is being called.

When it was initially decided to generate the custom screen, it should been generated in the Custom Function group instead of using the standard Function Group. I have suggested the same to client to fix this issue and guard the table maintenance from future upgrades.

Have you experience the pain of the table control definition?

Like It? Share!!

Don't miss an Update

Get notified of the new post, right into your inbox

Naimesh Patel{274 articles}

I'm SAP ABAP Consultant for more than a decade. I like to experiment with ABAP especially OO. I have been SDN Top Contributor.
Follow :

Explore all of his 274 articles.

Load comments

1 Comment

  • Jayanth

    Hi Naimesh,
    Thanks for the details, i’m about to work on an upgrade project from EHP4 to EHP6.
    Tips on what is expected from technical consultant will be helpful.

Comments on this Post are now closed. If you have something important to share, you can always contact me.

You seem to be new here. Subscribe to stay connected.