Friday, July 22, 2022

Readable ETC

 http://www.saptraininghq.com/how-to-modify-data-in-a-sap-database-table-using-abap/


Tuesday, July 19, 2022

Authority-check. Roles. User Profile

 Example usage


 AUTHORITY-CHECK OBJECT 'S_DEVELOP'
    "ID 'OJBNAME' FIELD 'AUTH'
    ID 'ACTVT'  FIELD '16' " 01, 02, 03, 06, 07, 16 (40 ... no more auth)
    ID 'ACTVT'  FIELD '01'" ....

 Note that for the user will be authorized above, the object 'S_DEVELOP' should be assigned to one of his assigned authorization profiles. The authorization profile is assigned to the Roles. These can be found in the user master data. Can be display via SU03d. Tcodes to create/display roles, objects, authorizations etc are PFCG, SUIM, SU20, SUO1, SuO1D. Tcode SUIM can be used to find the role with auth for that particular transaction, use Roles by Selection Criteria






How to debug database update tasks, message output type.

 1. Know how to replicate the program to debug. Get data to debug.

 2. If program is known, put external breakpoint (BP).  Plus All NACE routines, RSNASTED, etc. of the output type.

 3. Then run the program or tcode .  On the transaction screens, input all data. Then before saving the document. Activate debugger, or put /h in the command field.

 4. Once inside the debugger, check Update debugging.  Make it sure that it is check and activated. 

 5. Then press F8. Another debugging windows will open for the DB update. It should go to external BP.

  6. Usually the the program message update is open.




Friday, February 4, 2022

SAP idoc tips on its configuration and how it works in SAP -output determination processing and idoc creation

 

Use SAP tcode to configure output message and Idoc :

1. NACE (also via SPRO IMG) - maintain output message type,application, programs, output type, transmission medium,   condition tables/access, condition records...



2. WE20 (partner profile, as long as partner number/type is already created via WE21)

                             - also here indicates whether there is a process code to use for idoc creation or none.

                             - stored in table EDPP1, EDP12, EDP13

                               The process code contains the program that will process/create the IDOC.



Idoc Processing/creation  (like upon posting or saving the SAP document) :

1. The SAP application program (application such as ME) has corresponding program that collects and get all output message types that is configured on its application. Then save all to internal table KOMT1 -> NNAST . Example of the output determination program appliction in IM - SAMMM07M - SAPLV61B .



* the function module RV_MESSAGE_GET - collects all output types.


2. Then set access sequence and its condition records will be access by the program that will determine the final content of XNAST table. 



* the table NAST also contains the link between the output type and the document number created.

3. Then output message will link to the partner profile and its process code (function/program) during RV_MESSAGE_UPDATE. Wherein process code will be process or if none, the routine program indicated in the NACE. 

4. Then ouptut message type appears in the output of the documents. 

Use the following for Idoc error debugging


WE02, WE09, BD87, program RSNAST00 (issuing output, make it sure output type is send to job not immediate)

How to use BD87 to display or find the idoc  for that document.

1.  Enter Message type, Business Object and / or the Object key, date, or person creator. Specific much better.


To display business object type and object key

Once found, to display.




Use table NAST to look for the document created for that output message type.