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

Lock the whole table

Former Member
0 Likes
2,108

Hello,

I'm deleting a lot of records from a Z table but I want to block the whole table first. I already have a lock object for that

Is this correct to lock the entire table?

CALL FUNCTION 'ENQUEUE_Exxxxx'

EXPORTING

MODE_ZNS032EXTRHIST = 'E'

EXCEPTIONS

FOREIGN_LOCK = 1

SYSTEM_FAILURE = 2

OTHERS = 3.

Or should I specify any other exporting parameter?

Thanks in advance!

3 REPLIES 3
Read only

Former Member
0 Likes
971

Hi,

Mode E should be sufficient.

Pass the client also.

Regards,

Ankur Parab

Edited by: Ankur Parab on Jul 10, 2009 7:35 PM

Read only

Former Member
0 Likes
971

hi, you can use

CALL FUNCTION 'ENQUEUE_E_TABLEE'

or Fm VIEW_ENQUEUE passing action as E when locking

thanks

Read only

Former Member
0 Likes
971

Hi there,

I am not sure i got your requirements correctly.

The enqueue function module would just lock your table against any other requests to update/modify the table records untill you dequeue the table again.

If this is your requirement then the format mentioned by you is correct and this would lock the entire table.

Regards,

Jacky.