SAP HRIQ_AUDITRUN_CREATE_FROM_DATA Function Module for Save Audit Run Results
HRIQ_AUDITRUN_CREATE_FROM_DATA is a standard hriq auditrun create from data SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Save Audit Run Results processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for hriq auditrun create from data FM, simply by entering the name HRIQ_AUDITRUN_CREATE_FROM_DATA into the relevant SAP transaction such as SE37 or SE38.
Function Group: HRPIQ00AUDITFORMS
Program Name: SAPLHRPIQ00AUDITFORMS
Main Program: SAPLHRPIQ00AUDITFORMS
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function HRIQ_AUDITRUN_CREATE_FROM_DATA pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'HRIQ_AUDITRUN_CREATE_FROM_DATA'"Save Audit Run Results.
EXPORTING
IS_AUDR0 = "Audit Structure
* IV_COMMIT = ' ' "Checkbox
* IV_BUFFER_MODE = 'X' "Checkbox
* IV_1779_MODE = "
* IV_INPUT_CHECK = 'X' "Indicator
* IV_KEYDATE = SY-DATUM "Key Date
TABLES
* IT_1779 = "Infotype 1779 (Audits)
* IT_APPR_AUD3 = "Subrequirement Structure: Applicable Academic Work
* IT_APPR_AUD4 = "Audit Structure: Result Storage Yes/No
* IT_APPR_AUD5 = "Audit Structure: Calculation Result Folder
* ET_RETURN = "Return Parameter(s)
* IT_ASSIGNM = "Structure for Appraised Object
* IT_APPR = "Appraisal Management Data
* IT_APPEE = "Appraisee Structure
* IT_APPSER = "Structure for Appraiser and Appraisal GUID
* IT_AUDR1 = "Audit Structure: Result Storage
* IT_AUDR2 = "Audit Structure: Result Storage Yes/No
* IT_APPR_AUD1 = "Audit Structure: Result Storage
* IT_APPR_AUD2 = "Audit Structure: Result Storage Yes/No
IMPORTING Parameters details for HRIQ_AUDITRUN_CREATE_FROM_DATA
IS_AUDR0 - Audit Structure
Data type: PIQAPPR_AUDR0UPOptional: No
Call by Reference: No ( called with pass by value option)
IV_COMMIT - Checkbox
Data type: XFELDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_BUFFER_MODE - Checkbox
Data type: XFELDDefault: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_1779_MODE -
Data type: PIQUPDATEFLAGOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_INPUT_CHECK - Indicator
Data type: PIQFLAGDefault: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)
IV_KEYDATE - Key Date
Data type: PIQKEYDATEDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for HRIQ_AUDITRUN_CREATE_FROM_DATA
IT_1779 - Infotype 1779 (Audits)
Data type: P1779Optional: Yes
Call by Reference: Yes
IT_APPR_AUD3 - Subrequirement Structure: Applicable Academic Work
Data type: PIQAPPR_AUD3UPOptional: Yes
Call by Reference: Yes
IT_APPR_AUD4 - Audit Structure: Result Storage Yes/No
Data type: PIQAPPR_AUD4UPOptional: Yes
Call by Reference: Yes
IT_APPR_AUD5 - Audit Structure: Calculation Result Folder
Data type: PIQAPPR_AUD5UPOptional: Yes
Call by Reference: Yes
ET_RETURN - Return Parameter(s)
Data type: BAPIRET2Optional: Yes
Call by Reference: Yes
IT_ASSIGNM - Structure for Appraised Object
Data type: PIQAPPR_ASSIGNMUPOptional: Yes
Call by Reference: Yes
IT_APPR - Appraisal Management Data
Data type: PIQAPPR_APPRUPOptional: Yes
Call by Reference: Yes
IT_APPEE - Appraisee Structure
Data type: PIQAPPR_APPEEUPOptional: Yes
Call by Reference: Yes
IT_APPSER - Structure for Appraiser and Appraisal GUID
Data type: PIQAGR_APPSERUPOptional: Yes
Call by Reference: Yes
IT_AUDR1 - Audit Structure: Result Storage
Data type: PIQAUDR1UPOptional: Yes
Call by Reference: Yes
IT_AUDR2 - Audit Structure: Result Storage Yes/No
Data type: PIQAUDR2UPOptional: Yes
Call by Reference: Yes
IT_APPR_AUD1 - Audit Structure: Result Storage
Data type: PIQAPPR_AUD1UPOptional: Yes
Call by Reference: Yes
IT_APPR_AUD2 - Audit Structure: Result Storage Yes/No
Data type: PIQAPPR_AUD2UPOptional: Yes
Call by Reference: Yes
Copy and paste ABAP code example for HRIQ_AUDITRUN_CREATE_FROM_DATA Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.| DATA: | ||||
| lt_it_1779 | TYPE STANDARD TABLE OF P1779, " | |||
| lv_is_audr0 | TYPE PIQAPPR_AUDR0UP, " | |||
| lt_it_appr_aud3 | TYPE STANDARD TABLE OF PIQAPPR_AUD3UP, " | |||
| lt_it_appr_aud4 | TYPE STANDARD TABLE OF PIQAPPR_AUD4UP, " | |||
| lt_it_appr_aud5 | TYPE STANDARD TABLE OF PIQAPPR_AUD5UP, " | |||
| lt_et_return | TYPE STANDARD TABLE OF BAPIRET2, " | |||
| lv_iv_commit | TYPE XFELD, " SPACE | |||
| lt_it_assignm | TYPE STANDARD TABLE OF PIQAPPR_ASSIGNMUP, " | |||
| lt_it_appr | TYPE STANDARD TABLE OF PIQAPPR_APPRUP, " | |||
| lv_iv_buffer_mode | TYPE XFELD, " 'X' | |||
| lt_it_appee | TYPE STANDARD TABLE OF PIQAPPR_APPEEUP, " | |||
| lv_iv_1779_mode | TYPE PIQUPDATEFLAG, " | |||
| lt_it_appser | TYPE STANDARD TABLE OF PIQAGR_APPSERUP, " | |||
| lv_iv_input_check | TYPE PIQFLAG, " 'X' | |||
| lt_it_audr1 | TYPE STANDARD TABLE OF PIQAUDR1UP, " | |||
| lv_iv_keydate | TYPE PIQKEYDATE, " SY-DATUM | |||
| lt_it_audr2 | TYPE STANDARD TABLE OF PIQAUDR2UP, " | |||
| lt_it_appr_aud1 | TYPE STANDARD TABLE OF PIQAPPR_AUD1UP, " | |||
| lt_it_appr_aud2 | TYPE STANDARD TABLE OF PIQAPPR_AUD2UP. " |
|   CALL FUNCTION 'HRIQ_AUDITRUN_CREATE_FROM_DATA' "Save Audit Run Results |
| EXPORTING | ||
| IS_AUDR0 | = lv_is_audr0 | |
| IV_COMMIT | = lv_iv_commit | |
| IV_BUFFER_MODE | = lv_iv_buffer_mode | |
| IV_1779_MODE | = lv_iv_1779_mode | |
| IV_INPUT_CHECK | = lv_iv_input_check | |
| IV_KEYDATE | = lv_iv_keydate | |
| TABLES | ||
| IT_1779 | = lt_it_1779 | |
| IT_APPR_AUD3 | = lt_it_appr_aud3 | |
| IT_APPR_AUD4 | = lt_it_appr_aud4 | |
| IT_APPR_AUD5 | = lt_it_appr_aud5 | |
| ET_RETURN | = lt_et_return | |
| IT_ASSIGNM | = lt_it_assignm | |
| IT_APPR | = lt_it_appr | |
| IT_APPEE | = lt_it_appee | |
| IT_APPSER | = lt_it_appser | |
| IT_AUDR1 | = lt_it_audr1 | |
| IT_AUDR2 | = lt_it_audr2 | |
| IT_APPR_AUD1 | = lt_it_appr_aud1 | |
| IT_APPR_AUD2 | = lt_it_appr_aud2 | |
| . " HRIQ_AUDITRUN_CREATE_FROM_DATA | ||
ABAP code using 7.40 inline data declarations to call FM HRIQ_AUDITRUN_CREATE_FROM_DATA
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.| DATA(ld_iv_commit) | = ' '. | |||
| DATA(ld_iv_buffer_mode) | = 'X'. | |||
| DATA(ld_iv_input_check) | = 'X'. | |||
| DATA(ld_iv_keydate) | = SY-DATUM. | |||
Search for further information about these or an SAP related objects