SAP SAPBC_GLOBAL_AGENCY_CREATE Function Module for
SAPBC_GLOBAL_AGENCY_CREATE is a standard sapbc global agency create SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 sapbc global agency create FM, simply by entering the name SAPBC_GLOBAL_AGENCY_CREATE into the relevant SAP transaction such as SE37 or SE38.
Function Group: SAPBC_GLOBAL_TRAVELAGENCY
Program Name: SAPLSAPBC_GLOBAL_TRAVELAGENCY
Main Program:
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:
Function SAPBC_GLOBAL_AGENCY_CREATE 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 'SAPBC_GLOBAL_AGENCY_CREATE'".
EXPORTING
NAME = "
* LANGU = 'DE' "
* CURRENCY = "
STREET = "
* POSTBOX = "
POSTCODE = "
CITY = "
COUNTRY = "
REGION = "
* TELEPHONE = "
* URL = "
IMPORTING
AGENCYNUM = "
EXCEPTIONS
NO_ID_AVAILABLE = 1 INSERT_REJECTED = 2
IMPORTING Parameters details for SAPBC_GLOBAL_AGENCY_CREATE
NAME -
Data type: STRAVELAG-NAMEOptional: No
Call by Reference: No ( called with pass by value option)
LANGU -
Data type: STRAVELAG-LANGUDefault: 'DE'
Optional: Yes
Call by Reference: No ( called with pass by value option)
CURRENCY -
Data type: STRAVELAG-CURRENCYOptional: Yes
Call by Reference: No ( called with pass by value option)
STREET -
Data type: STRAVELAG-STREETOptional: No
Call by Reference: No ( called with pass by value option)
POSTBOX -
Data type: STRAVELAG-POSTBOXOptional: Yes
Call by Reference: No ( called with pass by value option)
POSTCODE -
Data type: STRAVELAG-POSTCODEOptional: No
Call by Reference: No ( called with pass by value option)
CITY -
Data type: STRAVELAG-CITYOptional: No
Call by Reference: No ( called with pass by value option)
COUNTRY -
Data type: STRAVELAG-COUNTRYOptional: No
Call by Reference: No ( called with pass by value option)
REGION -
Data type: STRAVELAG-REGIONOptional: No
Call by Reference: No ( called with pass by value option)
TELEPHONE -
Data type: STRAVELAG-TELEPHONEOptional: Yes
Call by Reference: No ( called with pass by value option)
URL -
Data type: STRAVELAG-URLOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for SAPBC_GLOBAL_AGENCY_CREATE
AGENCYNUM -
Data type: STRAVELAG-AGENCYNUMOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NO_ID_AVAILABLE -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INSERT_REJECTED -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for SAPBC_GLOBAL_AGENCY_CREATE 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_name | TYPE STRAVELAG-NAME, " | |||
lv_agencynum | TYPE STRAVELAG-AGENCYNUM, " | |||
lv_no_id_available | TYPE STRAVELAG, " | |||
lv_langu | TYPE STRAVELAG-LANGU, " 'DE' | |||
lv_currency | TYPE STRAVELAG-CURRENCY, " | |||
lv_street | TYPE STRAVELAG-STREET, " | |||
lv_insert_rejected | TYPE STRAVELAG, " | |||
lv_postbox | TYPE STRAVELAG-POSTBOX, " | |||
lv_postcode | TYPE STRAVELAG-POSTCODE, " | |||
lv_city | TYPE STRAVELAG-CITY, " | |||
lv_country | TYPE STRAVELAG-COUNTRY, " | |||
lv_region | TYPE STRAVELAG-REGION, " | |||
lv_telephone | TYPE STRAVELAG-TELEPHONE, " | |||
lv_url | TYPE STRAVELAG-URL. " |
  CALL FUNCTION 'SAPBC_GLOBAL_AGENCY_CREATE' " |
EXPORTING | ||
NAME | = lv_name | |
LANGU | = lv_langu | |
CURRENCY | = lv_currency | |
STREET | = lv_street | |
POSTBOX | = lv_postbox | |
POSTCODE | = lv_postcode | |
CITY | = lv_city | |
COUNTRY | = lv_country | |
REGION | = lv_region | |
TELEPHONE | = lv_telephone | |
URL | = lv_url | |
IMPORTING | ||
AGENCYNUM | = lv_agencynum | |
EXCEPTIONS | ||
NO_ID_AVAILABLE = 1 | ||
INSERT_REJECTED = 2 | ||
. " SAPBC_GLOBAL_AGENCY_CREATE |
ABAP code using 7.40 inline data declarations to call FM SAPBC_GLOBAL_AGENCY_CREATE
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."SELECT single NAME FROM STRAVELAG INTO @DATA(ld_name). | ||||
"SELECT single AGENCYNUM FROM STRAVELAG INTO @DATA(ld_agencynum). | ||||
"SELECT single LANGU FROM STRAVELAG INTO @DATA(ld_langu). | ||||
DATA(ld_langu) | = 'DE'. | |||
"SELECT single CURRENCY FROM STRAVELAG INTO @DATA(ld_currency). | ||||
"SELECT single STREET FROM STRAVELAG INTO @DATA(ld_street). | ||||
"SELECT single POSTBOX FROM STRAVELAG INTO @DATA(ld_postbox). | ||||
"SELECT single POSTCODE FROM STRAVELAG INTO @DATA(ld_postcode). | ||||
"SELECT single CITY FROM STRAVELAG INTO @DATA(ld_city). | ||||
"SELECT single COUNTRY FROM STRAVELAG INTO @DATA(ld_country). | ||||
"SELECT single REGION FROM STRAVELAG INTO @DATA(ld_region). | ||||
"SELECT single TELEPHONE FROM STRAVELAG INTO @DATA(ld_telephone). | ||||
"SELECT single URL FROM STRAVELAG INTO @DATA(ld_url). | ||||
Search for further information about these or an SAP related objects