OIDA_GET_ORIGIN_DESTINATION 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 OIDA_GET_ORIGIN_DESTINATION into the relevant SAP transaction such as SE37 or SE80.
Associated Function Group:
OIDA
Released Date:
Not Released
Processing type: Normal fucntion module
CALL FUNCTION 'OIDA_GET_ORIGIN_DESTINATION' "Get the orgin and destination field values from plant and ship-to
* EXPORTING
* i_werks = " vbap-werks Input plant: (get the ORIGIN field values)
* i_ship_to = " vbpa-kunnr Input ship-to: (get DESTINATION field values)
* i_po_so = " ekko-abgru
* i_vend = " ekko-lifnr
* i_rec_werks = " ekpo-werks
IMPORTING
e_oic_dcityc = " oic_pipe-oic_dcityc destination city code (from ship-to)
e_oic_dcounc = " oic_pipe-oic_dcounc destination county code (from ship-to)
e_oic_dregio = " oic_pipe-oic_dregio destination region code (from ship-to)
e_oic_oland1 = " oic_pipe-oic_oland1 origin country code (from plant)
e_oic_oregio = " oic_pipe-oic_oregio origin region code (from plant)
e_oic_ocounc = " oic_pipe-oic_ocounc origin county code (from plant)
e_oic_ocityc = " oic_pipe-oic_ocityc origin city code (from plant)
e_oic_dland1 = " oic_pipe-oic_dland1 destination country code (from ship-to)
. " OIDA_GET_ORIGIN_DESTINATION
The ABAP code below is a full code listing to execute function module OIDA_GET_ORIGIN_DESTINATION 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).
| ld_e_oic_dcityc | TYPE OIC_PIPE-OIC_DCITYC , |
| ld_e_oic_dcounc | TYPE OIC_PIPE-OIC_DCOUNC , |
| ld_e_oic_dregio | TYPE OIC_PIPE-OIC_DREGIO , |
| ld_e_oic_oland1 | TYPE OIC_PIPE-OIC_OLAND1 , |
| ld_e_oic_oregio | TYPE OIC_PIPE-OIC_OREGIO , |
| ld_e_oic_ocounc | TYPE OIC_PIPE-OIC_OCOUNC , |
| ld_e_oic_ocityc | TYPE OIC_PIPE-OIC_OCITYC , |
| ld_e_oic_dland1 | TYPE OIC_PIPE-OIC_DLAND1 . |
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_oic_dcityc | TYPE OIC_PIPE-OIC_DCITYC , |
| ld_i_werks | TYPE VBAP-WERKS , |
| ld_e_oic_dcounc | TYPE OIC_PIPE-OIC_DCOUNC , |
| ld_i_ship_to | TYPE VBPA-KUNNR , |
| ld_e_oic_dregio | TYPE OIC_PIPE-OIC_DREGIO , |
| ld_i_po_so | TYPE EKKO-ABGRU , |
| ld_e_oic_oland1 | TYPE OIC_PIPE-OIC_OLAND1 , |
| ld_i_vend | TYPE EKKO-LIFNR , |
| ld_e_oic_oregio | TYPE OIC_PIPE-OIC_OREGIO , |
| ld_i_rec_werks | TYPE EKPO-WERKS , |
| ld_e_oic_ocounc | TYPE OIC_PIPE-OIC_OCOUNC , |
| ld_e_oic_ocityc | TYPE OIC_PIPE-OIC_OCITYC , |
| ld_e_oic_dland1 | TYPE OIC_PIPE-OIC_DLAND1 . |
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 OIDA_GET_ORIGIN_DESTINATION or its description.
OIDA_GET_ORIGIN_DESTINATION - Get the orgin and destination field values from plant and ship-to OIDA_GET_EXTERNAL_DETAILS - Get the external details OIDA_EXTDET_SET - External Details control for LORD OIDA_DNITEM_DETERMINE_GIDOC - determine goods issue doc. no. of the delivery note item OIC_TRANSFER_SLA_DETAILS - F&A - Tranfer Details for Second Level Analysis OIC_SET_TRAFFIC_LIGHT - Translate evaluation status of F&A formula to traffic light color