Ansicht
Dokumentation

/FRE/UI_DIF_OCCURR_LOCK - Lock of DIF occurrences

/FRE/UI_DIF_OCCURR_LOCK - Lock of DIF occurrences

General Material Data   PERFORM Short Reference  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

This function locks the DIF Occurrences so that a user can modify DIF Occurrences and their attributes without other users trying to access. them at the same time. It returns the DIF Occurrences that have been locked and those that could not be locked.

A lock is set on the field:

  • DIFNR with the value given in the input table IT_DIF_KEY in the database table /FRE/DIF_OCCURR, and the related tables /FRE/DIF_OCC_TXT and /FRE/DIF_ASSIGN
  • MANDT with value SY-MANDT in the tables /FRE/DIF_OCCURR and /FRE/DIF_OCC_TXT
  • LANGU with value SY-LANGU in the table /FRE/DIF_OCC_TXT
  • LOCID and MATID are locked generically in the table /FRE/DIF_ASSIGN

If the function can lock all DIF Occurrences passed in input (IT_DIFNR), the function will return all DIF Occurrences in output (ET_DIFNR_LOCKED).

If an occurrence is already locked by another user, the function receives the input parameter I_DIALOG.

  • If I_DIALOG is set to 'X', the function will display a pop-up. The user must decide whether to see:
  • All DIF Occurrences he or she has selected in display mode. In that case, the function will unlock all DIF Occurrences. The table of locked DIF Occurrences (ET_DIFNR_LOCKED) will be empty and the table of unlocked DIF Occurrences (ET_DIFNR_NOT_LOCKED) will contain all DIF Occurrences for input. The lock status is set to 2.

  • Only the DIF Occurrences that are lockable (that means the user will be able to modify them). In that case the funtion will return output parameter ET_DIFNR_LOCKED for only those DIF Occurrences that have just been locked and ET_DIF_NR_NOT_LOCKED for those DIF Occurrences that could not be locked. The lock status is set to 1.

  • If the user cancels the dialog box, no lock will be set and the function will set the lock status to 3

  • If I_DIALOG is initial, the function will return output parameter ET_DIF_KEY only for those DIF Occurrences that have just been locked and will generate an exception.

Example

Notes

Further information





Parameters

ET_DIFNR_LOCKED
ET_DIFNR_NOT_LOCKED
E_LOCK_STATUS
IT_DIFNR
I_DIALOG

Exceptions

/FRE/CX_UI_DIF_LOCK_ER

Function Group

/SAPLUI_DIF

General Data in Customer Master   SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up  
This documentation is copyright by SAP AG.

Length: 2751 Date: 20240426 Time: 033427     sap01-206 ( 53 ms )