ESDUS table keeps parameters mostly for MM transactions, here is the list of t-codes for which I found some entries inside ESDUS:
- IA05
- MB24
- MB25
- MB51
- MB52
- MB59
- MB5TD
- ME21N
- ME22N
- ME23N
- ME25
- ME2K
- ME32K
- ME3K
- ME51N
- ME52N
- ME53N
- ME54N
- ME55
- ME56
- ME57
- ME58
- ME5A
- ME5F
- ME5K
- ME5W
- ME80AN
- ME80FN
- ME80RN
- MIGO
- MIRO
- ML81N
- SA38
- SE38
As you see the list contains some important transactions and knowing about ESDUS can help a bit in the life of abaper.
In all FMs in the interface or inside the code you can find a table with structure ESDUSCOM. This structures contains three components: ACTION, ELEMENT, ACTIVE. This components can be found of course in
ESDUS table. ACTION is responsible for the identification of program or transaction or object for which the settings are stored. ELEMENT keeps the setting key (name) and ACTIVE keeps the value.
Usage and names are of FMs are simillar to FMs. But let's look on them closer. will give you all parameters for a user for selected transaction / program / object. You always have to pass IACTION parameter - so the name of searched configuration. IUNAME if passed then FM returns settings for passed user, if parameter is not supplied then in default caller user is used. IDB parameter gives you an option to select data from DB directly, if this flag is not set then then selection from ESDUS table is done only if in function group memory there is no data about searched config. ILIKE parameter gives you possibility to use patterns, if this flag is set then selection from DB or FG memory is based on the pattern IACTION* for example. In such way you can select settings for example for Purchase Orders and Purchase Requisitions at once. Table IESDUS will contain results of the selection.
data: ft_esduscom type standard table of esduscom.
call function 'ES_READ_USER_SETTINGS'
exporting
iaction = 'PurchaseOrder'
* IUNAME = IUNAME
* IDB = IDB
* ILIKE = ILIKE
tables
iesdus = ft_esduscom.
If you'll want to add some settings to ESDUS then you'll need to pass configuration object in IACTION, configuration setting name in IELEMENT and it's value in IACTIVE. If you want to save the settings directly to DB then you need to set the flag in ISAVE parameter, in other case you'll need to call FM later.
call function 'ES_APPEND_USER_SETTINGS'
exporting
iaction = 'PurchaseOrder'
ielement = 'POHeaderProposer EKORG'
iactive = '0001'
* IUNAME = IUNAME
isave = 'X'
* TABLES
* IESDUS = IESDUS
.
Same way as you can add the configuration you can delete it. Parameters are the same.
call function 'ES_DELETE_USER_SETTINGS'
exporting
iaction = 'PurchaseOrder'
ielement = 'POHeaderProposer EKORG'
iactive = '0001'
* IUNAME = IUNAME
isave = 'X'
* TABLES
* IESDUS = IESDUS
exceptions
not_found = 1
others = 2
.
must be called if you want to save changes to DB and during calling of FM or you haven't pass flag for saving changes directly.
call function 'ES_SAVE_USER_SETTINGS'.
In the last part I'll give you some options which are available to configure in ESDUS / ESROU and description of how to go through the 4 scenarios from the
first part.