SAP Function Modules

MAINTAIN_IBAN SAP Function module - Process IBAN without Online Entry







MAINTAIN_IBAN is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name MAINTAIN_IBAN into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: IBMA
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM MAINTAIN_IBAN - MAINTAIN IBAN





CALL FUNCTION 'MAINTAIN_IBAN' "Process IBAN without Online Entry
  EXPORTING
    i_banks =                   " bnka-banks    Bank Country Key
    i_bankl =                   " bnka-bankl    Bank Key
    i_bankn =                   " reguh_bf-zbnkn  Bank Account Number of the Payee
    i_bkont =                   " reguh_bf-zbkon  Bank Control Key of the Payee's Bank
*   i_iban =                    " tiban-iban    IBAN (International Bank Account Number)
*   i_valid_from =              " sy-datum      Date and Time, Current (Application Server) Date
*   i_bkref =                   " reguh_bf-bkref  Reference specifications for bank details
*   i_tabname =                 " tiban-tabname  Table name, 16 characters
*   i_tabkey =                  " tiban-tabkey  IBAN origin: Key to table of bank details
*   i_iban_no_check =           " c
  IMPORTING
    e_iban =                    " tiban-iban    IBAN (International Bank Account Number)
    e_valid_from =              " sy-datum      Date and Time, Current (Application Server) Date
    e_return =                  " bapiret2      Return Parameters
  EXCEPTIONS
    IBAN_NOT_VALID = 1          "               IBAN is Not Valid
    BANK_NOT_FOUND = 2          "               Bank Does Not Exist
    NO_CONVERSION = 3           "               Generation Not Possible
    .  "  MAINTAIN_IBAN

ABAP code example for Function Module MAINTAIN_IBAN





The ABAP code below is a full code listing to execute function module MAINTAIN_IBAN including all data declarations. The code uses 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 original method of declaring data variables up front. 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).

DATA:
ld_e_iban  TYPE TIBAN-IBAN ,
ld_e_valid_from  TYPE SY-DATUM ,
ld_e_return  TYPE BAPIRET2 .


SELECT single BANKS
FROM BNKA
INTO @DATA(ld_i_banks).


SELECT single BANKL
FROM BNKA
INTO @DATA(ld_i_bankl).


DATA(ld_i_bankn) = some text here

DATA(ld_i_bkont) = some text here

SELECT single IBAN
FROM TIBAN
INTO @DATA(ld_i_iban).

DATA(ld_i_valid_from) = '20210129'.

DATA(ld_i_bkref) = some text here

SELECT single TABNAME
FROM TIBAN
INTO @DATA(ld_i_tabname).


SELECT single TABKEY
FROM TIBAN
INTO @DATA(ld_i_tabkey).

DATA(ld_i_iban_no_check) = '20210129'. . CALL FUNCTION 'MAINTAIN_IBAN' EXPORTING i_banks = ld_i_banks i_bankl = ld_i_bankl i_bankn = ld_i_bankn i_bkont = ld_i_bkont * i_iban = ld_i_iban * i_valid_from = ld_i_valid_from * i_bkref = ld_i_bkref * i_tabname = ld_i_tabname * i_tabkey = ld_i_tabkey * i_iban_no_check = ld_i_iban_no_check IMPORTING e_iban = ld_e_iban e_valid_from = ld_e_valid_from e_return = ld_e_return EXCEPTIONS IBAN_NOT_VALID = 1 BANK_NOT_FOUND = 2 NO_CONVERSION = 3 . " MAINTAIN_IBAN
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_e_iban  TYPE TIBAN-IBAN ,
ld_i_banks  TYPE BNKA-BANKS ,
ld_e_valid_from  TYPE SY-DATUM ,
ld_i_bankl  TYPE BNKA-BANKL ,
ld_e_return  TYPE BAPIRET2 ,
ld_i_bankn  TYPE REGUH_BF-ZBNKN ,
ld_i_bkont  TYPE REGUH_BF-ZBKON ,
ld_i_iban  TYPE TIBAN-IBAN ,
ld_i_valid_from  TYPE SY-DATUM ,
ld_i_bkref  TYPE REGUH_BF-BKREF ,
ld_i_tabname  TYPE TIBAN-TABNAME ,
ld_i_tabkey  TYPE TIBAN-TABKEY ,
ld_i_iban_no_check  TYPE C .


SELECT single BANKS
FROM BNKA
INTO ld_i_banks.


SELECT single BANKL
FROM BNKA
INTO ld_i_bankl.


ld_i_bankn = some text here

ld_i_bkont = some text here

SELECT single IBAN
FROM TIBAN
INTO ld_i_iban.

ld_i_valid_from = '20210129'.

ld_i_bkref = some text here

SELECT single TABNAME
FROM TIBAN
INTO ld_i_tabname.


SELECT single TABKEY
FROM TIBAN
INTO ld_i_tabkey.

ld_i_iban_no_check = '20210129'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name MAINTAIN_IBAN or its description.