cancel
Showing results for 
Search instead for 
Did you mean: 

Z Table and ENQUEUE question

andrew_jacobs2
Participant
0 Kudos

Hello,

I want to insert new records into a Z table.

Do I need to ENQUEUE the table?

If so, do I ENQUEUE the table on MANDT which will effectively lock the entire table?

Thx.

Andy

Accepted Solutions (1)

Accepted Solutions (1)

former_member555112
Active Contributor
0 Kudos

Hi,

If you want to avoid conflict during simultaneous updates on the table by different users then put enqueue on it. if you put enqueue on 'MANDT' field then entire table will be locked.

Regards,

Ankur Parab

Answers (2)

Answers (2)

SuhaSaha
Advisor
Advisor
0 Kudos

Hello Andy,

As suggested by Ankur it will lock the entire table & others will not be able to COMMIT the changes to the table.

But does this fit your bill? Is this your requirement? I will always prefer a lock on all the key fields of the table.

Please refer to this [post|; by Rob.

Awaiting other posts !!

BR,

Suhas

Edited by: Suhas Saha on Jun 18, 2009 5:15 PM

andrew_jacobs2
Participant
0 Kudos

Suhas,

I agree that when updating existing records, one must ENQUEUE the table with key fields, but in this case I'm inserting all new records. So the key fields do not exist.

Thx.

Andy

former_member212005
Active Contributor
0 Kudos

Andy...in that case you do not have to Enqueue the Z database table..

former_member212005
Active Contributor
0 Kudos

I dont think so that you need to enqueue the Z table...

You can carry ahead without any worry..

Moreover if you enqueue the table on MANDT...the entire table will be locked...i believe so..

Though I dont think so..that we use it in this manner..normally we lock records..by specifying primary keys as part of lock parameter.

Normally...we enqueue the database table..if there are any other processes which may also access the same database table for update..

Example..we usually lock KNA1 database table..when we are performing an update on it...the reason being, in live environment there are chances of a changing the customer and corrupting the entries

For a Z table I dont think so...and if it will be run nightly..then no need...