SAP FMAVC_DERI_CONTROL_OBJECT Function Module for Derive the availability control object from an FM account assignment
FMAVC_DERI_CONTROL_OBJECT is a standard fmavc deri control object SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Derive the availability control object from an FM account assignment 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 fmavc deri control object FM, simply by entering the name FMAVC_DERI_CONTROL_OBJECT into the relevant SAP transaction such as SE37 or SE38.
Function Group: FMAVC_DERI_TOOLS
Program Name: SAPLFMAVC_DERI_TOOLS
Main Program: SAPLFMAVC_DERI_TOOLS
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function FMAVC_DERI_CONTROL_OBJECT 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 'FMAVC_DERI_CONTROL_OBJECT'"Derive the availability control object from an FM account assignment.
EXPORTING
I_FM_AREA = "Financial management area
* I_FLG_FILL_ACO_OBJNR = ' ' "Flag: Fill the exporting parameter E_ACO_OBJNR
* I_FLG_FILL_CG_BA_OBJNR = ' ' "Flag: Fill the exp. parameter E_CG_BA_OBJNR, if cover eligibility rule is used
* I_ADDRSTRATID = "Strategy ID
* I_ADDRRULE = "Strategy for Deriving Control Objects From Budget Objects
* I_DERIACOGRANT = "Derivation of the Grant in Availability Control Objects (FM)
I_FISCYEAR = "Fiscal year
I_S_ADDRESS = "FM dimensions
I_SLDNR = "Source ledger number
I_ALDNR = "Availability ledger
* I_FLG_POSTING_OBJECT = ' ' "Flag: Derive ACO from a posting object
* I_FLG_RIB_RULE = ' ' "Flag: Derive ACO from RIB rule (call procedure)
* I_FLG_UPD_IDX = ' ' "Flag: Update index table
* I_FLG_BYPASS_IDX = ' ' "Flag: Bypass index table
IMPORTING
E_S_ACO_ADDRESS = "Availability control object dimensions
E_ACO_OBJNR = "Object number for FM budgeting and AVC
E_FLG_COVER_ELIGIBILITY = "Flag: Cover eligibility rule is used
E_FLG_USE_CALL_RIB = "Flag: Call RIB used?
E_COVER_GROUP = "Cover Group
E_CG_BUDGET_ADDRESS = "Budget Address in Cover Group
E_CG_BA_OBJNR = "Object number for FM budgeting and AVC
E_CGADDRIND = "Role of Budget Address in Cover Group
EXCEPTIONS
DERIVATION_FAILED = 1 INVALID_CONTROL_OBJECT = 2
IMPORTING Parameters details for FMAVC_DERI_CONTROL_OBJECT
I_FM_AREA - Financial management area
Data type: FIKRSOptional: No
Call by Reference: Yes
I_FLG_FILL_ACO_OBJNR - Flag: Fill the exporting parameter E_ACO_OBJNR
Data type: XFELDDefault: ' '
Optional: Yes
Call by Reference: Yes
I_FLG_FILL_CG_BA_OBJNR - Flag: Fill the exp. parameter E_CG_BA_OBJNR, if cover eligibility rule is used
Data type: XFELDDefault: ' '
Optional: Yes
Call by Reference: Yes
I_ADDRSTRATID - Strategy ID
Data type: BUAVC_ADDRSTRATID0Optional: Yes
Call by Reference: No ( called with pass by value option)
I_ADDRRULE - Strategy for Deriving Control Objects From Budget Objects
Data type: FMAVC_ADDRRULEOptional: Yes
Call by Reference: No ( called with pass by value option)
I_DERIACOGRANT - Derivation of the Grant in Availability Control Objects (FM)
Data type: FMAVC_DERIACOGRANTOptional: Yes
Call by Reference: No ( called with pass by value option)
I_FISCYEAR - Fiscal year
Data type: GJAHROptional: No
Call by Reference: Yes
I_S_ADDRESS - FM dimensions
Data type: FMKU_S_DIMPARTOptional: No
Call by Reference: Yes
I_SLDNR - Source ledger number
Data type: BUBAS_SLDNROptional: No
Call by Reference: Yes
I_ALDNR - Availability ledger
Data type: BUAVC_ALDNROptional: No
Call by Reference: Yes
I_FLG_POSTING_OBJECT - Flag: Derive ACO from a posting object
Data type: XFELDDefault: ' '
Optional: Yes
Call by Reference: Yes
I_FLG_RIB_RULE - Flag: Derive ACO from RIB rule (call procedure)
Data type: XFELDDefault: ' '
Optional: Yes
Call by Reference: Yes
I_FLG_UPD_IDX - Flag: Update index table
Data type: XFELDDefault: ' '
Optional: Yes
Call by Reference: Yes
I_FLG_BYPASS_IDX - Flag: Bypass index table
Data type: XFELDDefault: ' '
Optional: Yes
Call by Reference: Yes
EXPORTING Parameters details for FMAVC_DERI_CONTROL_OBJECT
E_S_ACO_ADDRESS - Availability control object dimensions
Data type: FMAVC_S_DIMENSIONSOptional: No
Call by Reference: Yes
E_ACO_OBJNR - Object number for FM budgeting and AVC
Data type: BUBAS_OBJNROptional: No
Call by Reference: Yes
E_FLG_COVER_ELIGIBILITY - Flag: Cover eligibility rule is used
Data type: XFELDOptional: No
Call by Reference: Yes
E_FLG_USE_CALL_RIB - Flag: Call RIB used?
Data type: XFELDOptional: No
Call by Reference: Yes
E_COVER_GROUP - Cover Group
Data type: FMCE_CVRGRPOptional: No
Call by Reference: Yes
E_CG_BUDGET_ADDRESS - Budget Address in Cover Group
Data type: FMKU_S_DIMPARTOptional: No
Call by Reference: Yes
E_CG_BA_OBJNR - Object number for FM budgeting and AVC
Data type: BUBAS_OBJNROptional: No
Call by Reference: Yes
E_CGADDRIND - Role of Budget Address in Cover Group
Data type: FMCE_CGADDRINDOptional: No
Call by Reference: Yes
EXCEPTIONS details
DERIVATION_FAILED - Call of the derivation tool failed
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INVALID_CONTROL_OBJECT - Derived availability control object does not exist
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for FMAVC_DERI_CONTROL_OBJECT 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: | ||||
| lv_i_fm_area | TYPE FIKRS, " | |||
| lv_e_s_aco_address | TYPE FMAVC_S_DIMENSIONS, " | |||
| lv_derivation_failed | TYPE FMAVC_S_DIMENSIONS, " | |||
| lv_i_flg_fill_aco_objnr | TYPE XFELD, " ' ' | |||
| lv_i_flg_fill_cg_ba_objnr | TYPE XFELD, " ' ' | |||
| lv_i_addrstratid | TYPE BUAVC_ADDRSTRATID0, " | |||
| lv_i_addrrule | TYPE FMAVC_ADDRRULE, " | |||
| lv_i_deriacogrant | TYPE FMAVC_DERIACOGRANT, " | |||
| lv_i_fiscyear | TYPE GJAHR, " | |||
| lv_e_aco_objnr | TYPE BUBAS_OBJNR, " | |||
| lv_invalid_control_object | TYPE BUBAS_OBJNR, " | |||
| lv_i_s_address | TYPE FMKU_S_DIMPART, " | |||
| lv_e_flg_cover_eligibility | TYPE XFELD, " | |||
| lv_i_sldnr | TYPE BUBAS_SLDNR, " | |||
| lv_e_flg_use_call_rib | TYPE XFELD, " | |||
| lv_i_aldnr | TYPE BUAVC_ALDNR, " | |||
| lv_e_cover_group | TYPE FMCE_CVRGRP, " | |||
| lv_e_cg_budget_address | TYPE FMKU_S_DIMPART, " | |||
| lv_i_flg_posting_object | TYPE XFELD, " ' ' | |||
| lv_e_cg_ba_objnr | TYPE BUBAS_OBJNR, " | |||
| lv_i_flg_rib_rule | TYPE XFELD, " ' ' | |||
| lv_e_cgaddrind | TYPE FMCE_CGADDRIND, " | |||
| lv_i_flg_upd_idx | TYPE XFELD, " ' ' | |||
| lv_i_flg_bypass_idx | TYPE XFELD. " ' ' |
|   CALL FUNCTION 'FMAVC_DERI_CONTROL_OBJECT' "Derive the availability control object from an FM account assignment |
| EXPORTING | ||
| I_FM_AREA | = lv_i_fm_area | |
| I_FLG_FILL_ACO_OBJNR | = lv_i_flg_fill_aco_objnr | |
| I_FLG_FILL_CG_BA_OBJNR | = lv_i_flg_fill_cg_ba_objnr | |
| I_ADDRSTRATID | = lv_i_addrstratid | |
| I_ADDRRULE | = lv_i_addrrule | |
| I_DERIACOGRANT | = lv_i_deriacogrant | |
| I_FISCYEAR | = lv_i_fiscyear | |
| I_S_ADDRESS | = lv_i_s_address | |
| I_SLDNR | = lv_i_sldnr | |
| I_ALDNR | = lv_i_aldnr | |
| I_FLG_POSTING_OBJECT | = lv_i_flg_posting_object | |
| I_FLG_RIB_RULE | = lv_i_flg_rib_rule | |
| I_FLG_UPD_IDX | = lv_i_flg_upd_idx | |
| I_FLG_BYPASS_IDX | = lv_i_flg_bypass_idx | |
| IMPORTING | ||
| E_S_ACO_ADDRESS | = lv_e_s_aco_address | |
| E_ACO_OBJNR | = lv_e_aco_objnr | |
| E_FLG_COVER_ELIGIBILITY | = lv_e_flg_cover_eligibility | |
| E_FLG_USE_CALL_RIB | = lv_e_flg_use_call_rib | |
| E_COVER_GROUP | = lv_e_cover_group | |
| E_CG_BUDGET_ADDRESS | = lv_e_cg_budget_address | |
| E_CG_BA_OBJNR | = lv_e_cg_ba_objnr | |
| E_CGADDRIND | = lv_e_cgaddrind | |
| EXCEPTIONS | ||
| DERIVATION_FAILED = 1 | ||
| INVALID_CONTROL_OBJECT = 2 | ||
| . " FMAVC_DERI_CONTROL_OBJECT | ||
ABAP code using 7.40 inline data declarations to call FM FMAVC_DERI_CONTROL_OBJECT
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_i_flg_fill_aco_objnr) | = ' '. | |||
| DATA(ld_i_flg_fill_cg_ba_objnr) | = ' '. | |||
| DATA(ld_i_flg_posting_object) | = ' '. | |||
| DATA(ld_i_flg_rib_rule) | = ' '. | |||
| DATA(ld_i_flg_upd_idx) | = ' '. | |||
| DATA(ld_i_flg_bypass_idx) | = ' '. | |||
Search for further information about these or an SAP related objects