Fonction SAP BAPI_XMI_SET_AUDITLEVEL - Set Audit Level of an XMI Session

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
AUDITLEVEL BAPIXMLOGR-AUDITLEVEL N 1 X Required audit level

Paramètre Reférence Type Long. Description
RETURN BAPIRET2 u 548

Functionality
Use this method to determine the global audit level for the XMISESSIONlog. The audit level controls which messages are logged with sessionswith the CCMS system administration interfaces.

Background information: The audit level and the XMISESSION log
The XMISESSION log contains messages that are transitted by externalproducts, and messages that occur in the CCMS interface functions.Although the XMI log receives a statement for actions that weretriggered externally, developers can also use it to restrict errorswhen programming external tools.
The routine that stores messages has a parameter that is identified asthe audit level. This audit level determines whether this is a messagethat needs to be logged (audit level=0) or if it is a message thatdelivers additional information (higher level of detail).
This works as follows: XMISESSION contains a global XMI audit level(default=0). This can be set explicity by an external product usingthis method and has the effect of a filter for transmitted messages.
If an external product logs onto several CCMS interfaces during one RFCsession, then the XMISESSION audit level is the last value that wasset.
If the system now generates a message with the target XMISESSION log,the system compares the XMISESSION audit level with the audit level ofmessage function. If the value with the called method is less than orequal to the global XMI audit level, then the system makes an entry inthe log. For example, if messages are transmitted with audit level 3 -however the XMISESSION audit level is only 2 - then these messages arenot stored in the XMI log.
If the global XMI audit level is not set explicitly by the externaltools, it is set at 0 (minimal). This means that only the mostimportant statements are logged.
When you open a new RFC session, the audit level is again set to 0.

Further information
XMI documentation (SAPnet/CCMS)

Description
INCLUDE BAPI_TABLE

Value range
MSG_NOT_LOGGED_ON: Noone has logged onto the R/3 System.
MSG_PROBLEM_DETECTED: A problem occurred in an XMI function module thatis not directly connected to the XMI functions. The problem wasprobably caused by a called function module. To analyze the problem,examine the R/3 System log.
MSG_CANT_LOG_ACTION: The action had to be terminated because the R/3XMI logging mechanism reported an error.

Description
Use this parameter to specify the audit level for logging messages inthe XMI log. The audit level applies to all sessions with CCMSinterfaces within one RFC session with the R/3 System.

Value range
0 - 4:

  • 0: Default value. All calls that modify the database are logged.

  • 1: As 0, error messages are also logged.

  • 2: As 1, all calls that read the database are logged.

  • 3: All calls and messages are logged (trace).