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

ZINDX table

Former Member
0 Likes
1,404

Experts,

I read below posts by Horst Keller and Sandra Rossi where they had mentioned not to use INDX table for custom programs as this is meant for use by SAP programs.

https://wiki.scn.sap.com/wiki/display/ABAP/Warning+about+inserting+custom+data+in+the+INDX+table

https://answers.sap.com/questions/228371/comand-field-n.html?childToView=228607#answer-228607

I have a scenario where there are 2 user exits for delivery creation in which custom code for route determination has been written. I want value from user exit 1 that gets called first in user exit 2 which is called next. I exported the values to INDX table from exit 1 and consumed in exit 2. Worked perfectly for 1 delivery.

In PRD, when multiple deliveries are created in mass(in background), Basis team identified several locks generated in INDX table.

Question:

1) Is it good to created custom table ZINDX in this scenario and all the developers to use this going forward? In that case, won't we end up generating locks on this custom table?

2) What is a better practice for this scenario?

BR,

Aspire

Experts,

I read below posts by Horst Keller and Sandra Rossi where they had mentioned not to use INDX table for custom programs as this is meant for use by SAP programs.

https://wiki.scn.sap.com/wiki/display/ABAP/Warning+about+inserting+custom+data+in+the+INDX+table

https://answers.sap.com/questions/228371/comand-field-n.html?childToView=228607#answer-228607

I have a scenario where there are 2 user exits for delivery creation in which custom code for route determination has been written. I want value from user exit 1 that gets called first in user exit 2 which is called next. I exported the values to INDX table from exit 1 and consumed in exit 2. Worked perfectly for 1 delivery.

In PRD, when multiple deliveries are created in mass(in background), Basis team identified several locks generated in INDX table.

Question:

1) Is it good to created custom table ZINDX in this scenario and all the developers to use this going forward? In that case, won't we end up generating locks on this custom table?

2) What is a better practice for this scenario?

BR,

Aspire

5 REPLIES 5
Read only

Sandra_Rossi
Active Contributor
0 Likes
1,274

I don't answer your question, but want to clarify the recommendation of using of ZINDX (it's only my point of view):

  • I think it's clear why custom programs should not update the standard table INDX, because it costs nothing to create an equivalent custom table ZINDX, and it avoids unwanted side effects (whatever they could be; doing so is called a "precautionary principle").
  • The recommendation of using ZINDX is not related specifically to locks but it could be one of the side effects.
Read only

Sandra_Rossi
Active Contributor
0 Likes
1,274

There are some SAP notes which give recommendations how to identify the cause of database locks, depending on the database you use. You could have a look at them.

Depending on the exact context how the user exits 1 and 2 are executed, you could maybe think to other solutions. If you want more help, you should give much more information. Currently, it's way too general.

Read only

Former Member
0 Likes
1,274

Sandra,

Thanks a bunch for your quick reply. It's very helpful. Let me get back here with details about the exits from the developer.

BR,

Aspire

Read only

1,274

Please use the COMMENT button for comments, questions, adding details, etc., ANSWER is only to propose a solution, dixit SAP text at the right of the answer area.

Read only

Former Member
0 Likes
1,274

By subsequent calls do you mean the two user exits are called in the same internal session? If they do, why do you involve persistence layer at all? Use a class implementing the singletion design pattern with setter-getter methods.