In this tutorial, I will explain how to create a table maintenance generator in the SAP ABAP. Also, I will explain how to check entries in TMG from SAP ABAP.
We will see in a brief way with the step-by-step approach to creating a table maintenance generator in SAP ABAP.
Table Maintenance Generator in SAP ABAP
It is a tool to maintain the table maintenance program. We can create, add, edit, and delete entries or records from the table through the table maintenance generator in SAP ABAP.
Also, Read: How to Create a Package in SAP ABAP
Check the TMG in SM30 Tcode
Follow the below steps to check whether the TMG has been created already or not for the table.
Step-1:
- The first step is to check transaction code sm30 to confirm whether TMG is already created or not. Open SAP ABAP, Type sm30 in the search box and hit enter.
- Type the existing table name and check by clicking the Display option. Here I’m taking a previous table ztsi and when I try to see the TMG for this table it’s not showing so TMG is not created for this table.
Since it is not created earlier. So, TMG is not visible to us.
Check out: How to Create Lock Object in SAP ABAP?
Create TMG in SE11 Table in SAP ABAP
Now, we will see how to create TMG in SAP ABAP in the TCODE SE11. Follow the below steps to do so.
Step-1:
- Go back to SE11 or click F3 to create TMG in SAP ABAP.
Step-2:
- Type the table name for which you want to create a table maintenance group and click Display. Since it is already created table, we can click directly the Display option. Here I have taken a table name ZTSI to create a TMG.
Step-3:
- The fields page will appear. Go to More -> Utilities -> Table Maintenance Generator.
Step-4:
- Now TMG Generation Environment page will open. Then we have to fill the necessary details like authorization group, function group, etc.
- Give an Authorization Group as NC which we can scroll down from the list and fill the Function Group as per your wish. Here I have given the table name ztsi_fg where fg stands for function group.
- Select the Maintenace Type as two-step and Recording Routine as no, or user, recording routine.
This is the method to create a Table maintenance generator in SAP ABAP.
Finding Screen Numbers in TMG
Let’s check how to find the screen numbers in the TMG screen.
Step-5:
- The next step is to find the screen numbers in the se11 TMG creation method. After giving all the details, we have to click on Find Scr.Number(s).
- Then click Propose screen number(s) and click tickmark.
Step-6:
- Click on the cover-like symbol near Find Scr.Number(s) to confirm the package for the creation of the table maintenance generator. It will show the name of the package with created data and click the save symbol.
Step-7:
- Click that save icon two times and it will automatically be created.
In this method, we should create a table maintenance generator in SAP ABAP.
Have a look: How to Create Table in SAP ABAP [With Columns]
How to Check Entries in SM30 after Created TMG
Below are the points to check entries in SM30 Tcode once created TMG.
- After TMG is created we have to see the entries which are reflected in the table maintenance group (sm30) or not. Type sm30 and enter then type the table name and click Maintain on the same page.
- The output of the table ZTSI has been shown in the TMG creation. The same entries or records can see here too.
By this method, we can check entries in the table maintenance group(TMG) in SAP ABAP.
How to Add Entries in the SM30 TMG
The main reason for creating TMG is to create, modify, and delete. So here we will see how to add entries to the existing entries in sm30 TMG.
- Click New Entries at the top of the same page once we click Maintain to add the required entries.
- You can add the ID, name, and phone number in the SM30 TMG to get extra records. Make sure to save once you added in the entries, else in the display it will not show.
- The added entries will be displayed finally in the output.
This is how we have to add entries in TMG.
Check Post: Operators in SAP HANA Cloud
How to Check Added Entries in the Table from SE11
We have created a TMG in SM30 and added the entries in SM30. Now we have to check back whether the entries have been reflected in the table or not.
- Go back to the SE11 and hit enter to check the entries in the table.
- Type the exact table name and click Display to see the entries added to the ZTSI table( Since we have created TMG for this table only).
- The table created with the fields page will open. Now go to More -> Utilities -> Table Contents -> Display.
- Now the selection screen page will be open. Go to More-> Program -> Execute to see the final output in the se11 table.
- The final output will be displayed with the entries we added to the table maintenance generator(TMG).
In this method, we have to check added entries in the TMG from SAP ABAP.
Moreover, you may like some more SAP tutorials:
- How to Install ABAP Development Tools
- How to Create SAP ABAP List View Report (ALV)
- SAP HANA Cloud ABAP Environment
- What is SAP BTP Cockpit?
Conclusion
This tutorial clearly explained how to create a table maintenance generator and also checked the se11 output table to verify whether it has been created properly or not. Below are the topics covered in this tutorial.
- Table Maintenance Generator in SAP ABAP
- Check the TMG in SM30 Tcode
- Create TMG in the SE11 table in SAP ABAP
- Finding screen numbers in TMG
- How to check entries in SM30 after creating TMG
- How to Add entries in the SM30 TMG
- How to check added entries in the table from SE11
I am Chris Waldron, working as a Senior SAP HANA Consultant at Halliburton, Houston, Texas, United States. I have been working in SAP for more than 15 years, especially in SAP IT consulting and business consulting. I worked in various industries in Sales & Distribution, Customer Relationship Management, banking, Risk Management, etc. And I am an SAP Certified Development Specialist – ABAP for SAP HANA 2.0 and SAP HANA Modeling Certified consultant. Read more