Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Table maintanace generator

Former Member
0 Likes
786

Hi All,

I have a requirement like I need to from a maintenance view of custom table i.e. Ztable I need to remove the Delete button from application tool bar? Is there any way to achieve this thing so that user can’t able to delete the existing records in the data base? if any sample code is there r where i need to do the modification in the function group related to this table maintenance view.

Thanks In Advance

8 REPLIES 8
Read only

Former Member
0 Likes
760

Hi,

You can create a maintenance view in SE11 for the custom table..

GO to SE11

Give a view name ZVIEW_TABLE.

Press create..

In the popup choose maintenance view..

In the table/join conditions tab give the table name..

In the view flds tab give the fields that you want..

<b>In the Maint. status tab Choose the radio button "Read and change"</b>

Save and generate the view..

Now in the menu..UTILTIES -> TABLE MAINTENANCE GENERATOR..

Generate the TM..

After generating go to SM30..

Give the view name..

You will not get the delete button...

Thanks,

Naren

Read only

0 Likes
760

thanq for u r replay Mr Narendran

but i was already created the table maintenance generator and i am able to view that in SM30 transaction my problem is when user go to change mode i need to restricts him not to change existing records for this i am planning to degrade the delete button. is there any way to do this.

Read only

Former Member
0 Likes
760

Hi,

If you don't want to create another TM, then you can give an error message in PAI if the user presses the delete button..I am not sure how to suppress the delete button other than using MAINTENANCE VIEW...

Thanks,

Naren

Read only

Former Member
0 Likes
760

I think you can probably do this with authorizations.

Rob

Read only

Former Member
0 Likes
760

There are two options:

1. Database view.

While creating the view, choose "database view" instead of maintenance view. This is used on for display purposes and not for changing or delete.

2. Or in the maintenance view, you can use events like before save event "01", which you can use to check for action = 'X' , which means "Delete". And restrict such actions by giving an error message & setting vim_abort_Saving = 'X'.

Read only

0 Likes
760

Best way is to use

option "read and change" form the tab "Maint.Status" in the maintenance view.

This allow only to "Read and Change" but not delete.

Read only

0 Likes
760

After you change to "read and change" do not forget to re-generate the maintenance view in "Expert Mode".

Read only

Former Member
0 Likes
760

hi..

hava a look on this tcode SE54.

this may be helpful, i think.

shamim.