Fonction SAP BAPI_GL_GETGLACCBALANCE - Closing balance of G/L account for chosen year

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
COMPANYCODE BAPI1028_0-COMP_CODE C 4 Company code
CURRENCYTYPE BAPI1028_5-CURR_TYPE C 2 Currency type
FISCALYEAR BAPI1028_3-FISC_YEAR N 4 Fiscal year
GLACCT BAPI1028_0-GL_ACCOUNT C 10 G/L account number

Paramètre Reférence Type Long. Description
ACCOUNT_BALANCE BAPI1028_3 u 38 Closing balance of G/L account in one year
RETURN BAPIRETURN u 452 Return code

Functionality
This method provides the ending balance of a G/L account for the fiscalyear selected.
The user decides whether the balance is provided in the transaction orcompany code currency. Exceptions are G/L accounts kept in varioustransaction currencies. In such cases, only the company code currencyis allowed.
The balance determined by the system and the currency are provided.Should problems arise, they are reported in a return code.

Notes
The same authorization checks are carried out as those for displayauthorization within a R/3 transaction.
The entry parameter COMPANYCODE is not converted, so that the leadingzeros in this parameter are not cleared. This is also the case forparameter GLACCT. G/L account numbers have to be entered with leadingzeros (for example, 0000113100).
Messages are provided in parameter RETURN. In the parameterdocumentation, you can find information on return values and theirmeanings.

Description
The G/L account balance is provided in a structure. You can findinformation on the meaning of the parameters in the corresponding dataelement documentation.
Structure setup
COMP_CODE Company code
GL_ACCOUNT G/L account number
FISC_YEAR Fiscal year
BALANCE Account balance
CURRENCY Currency key

Description
The return code of the method is provided in a structure with fivefields. You can find information on the meaning of the individualfields in the corresponding data element documentation.
Structure setup
TYPE Message type
CODE Message code
MESSAGE Message text
LOG_NO Application log: Log number
LOG_MSG_NO Application log: Current number of message

Description
You can find information on the meaning of company code in thecorresponding data element documentation:
Company code

Description
You can find information on the meaning of currency type in thecorresponding data element documentation:
Currency type

Value range
00 = Balance in transaction currency
10 = Balance in local currency

Description
You can find information on the meaning of fiscal year in thecorresponding data element documentation:
Fiscal year

Description
You can find information on the meaning of G/L account number in thecorresponding data element documentation.
G/L account number