SAP OIRE_GET_KALSM Function Module for Determine the pricing procedure from the business location









OIRE_GET_KALSM is a standard oire get kalsm SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Determine the pricing procedure from the business location 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 oire get kalsm FM, simply by entering the name OIRE_GET_KALSM into the relevant SAP transaction such as SE37 or SE38.

Function Group: OIRE_PC_DTF
Program Name: SAPLOIRE_PC_DTF
Main Program: SAPLOIRE_PC_DTF
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function OIRE_GET_KALSM 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 'OIRE_GET_KALSM'"Determine the pricing procedure from the business location
EXPORTING
I_PBLNR = "Business location identifier (IS-Oil MRN)
I_CHOBJ = "SSR PC: Clearing house
I_VKDAT = "SSR PC: Sales date at the service station
I_VKTIM = "SSR PC: Time of sale
I_PROCID = "Process ID
* I_CCINS = "SSR PC: Payment card type
* I_BUKRS = "Company code
* I_KALVG = "Document key

IMPORTING
E_KALSM = "Procedure (pricing, output control, acct. det., costing,...)
E_KSCHL = "Condition type

TABLES
TI_OIRA2_BBP1 = "Business location parameters

EXCEPTIONS
PBLNR_DOES_NOT_EXIST = 1 NO_CLEARING_HOUSE_DATA = 10 NEITHER_PBLNR_NOR_CH_PASSED = 11 KALSM_DOES_NOT_EXIST = 2 NO_PRICING_PROCEDURE = 3 NO_KALVG_WAS_DETERMINED = 4 NO_LOCATION_VALUES_FOUND = 5 NO_PARTNER_PROFILE = 6 NO_RNBT_FOR_PROCID = 7 NO_ENTRY_IN_T683S = 8 NO_ENTRY_IN_T685A = 9
.



IMPORTING Parameters details for OIRE_GET_KALSM

I_PBLNR - Business location identifier (IS-Oil MRN)

Data type: OIREUPLKXXXX-PBLNR
Optional: No
Call by Reference: No ( called with pass by value option)

I_CHOBJ - SSR PC: Clearing house

Data type: OIRECH-CHOBJ
Optional: No
Call by Reference: No ( called with pass by value option)

I_VKDAT - SSR PC: Sales date at the service station

Data type: OIREUPLKXXXX-VKDAT
Optional: No
Call by Reference: No ( called with pass by value option)

I_VKTIM - SSR PC: Time of sale

Data type: OIREUPLKXXXX-VKTIM
Optional: No
Call by Reference: No ( called with pass by value option)

I_PROCID - Process ID

Data type: OIRAPROCDEF-PROCDEF
Optional: No
Call by Reference: No ( called with pass by value option)

I_CCINS - SSR PC: Payment card type

Data type: OIREUPLKXXXX-SSR_CCINS
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_BUKRS - Company code

Data type: T001-BUKRS
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_KALVG - Document key

Data type: T683V-KALVG
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for OIRE_GET_KALSM

E_KALSM - Procedure (pricing, output control, acct. det., costing,...)

Data type: T683-KALSM
Optional: No
Call by Reference: Yes

E_KSCHL - Condition type

Data type: T685A-KSCHL
Optional: No
Call by Reference: Yes

TABLES Parameters details for OIRE_GET_KALSM

TI_OIRA2_BBP1 - Business location parameters

Data type: OIRA2_BBP1
Optional: No
Call by Reference: Yes

EXCEPTIONS details

PBLNR_DOES_NOT_EXIST - Business location is not created yet.

Data type:
Optional: No
Call by Reference: Yes

NO_CLEARING_HOUSE_DATA - No clearing house data was found.

Data type:
Optional: No
Call by Reference: Yes

NEITHER_PBLNR_NOR_CH_PASSED - Neither the PBLNR nor the CH was passed.

Data type:
Optional: No
Call by Reference: Yes

KALSM_DOES_NOT_EXIST - Pricing procedure does not exist

Data type:
Optional: No
Call by Reference: Yes

NO_PRICING_PROCEDURE - No pricing procedure could be determined

Data type:
Optional: No
Call by Reference: Yes

NO_KALVG_WAS_DETERMINED - No CustDocProcKey (KALVG) was determined

Data type:
Optional: No
Call by Reference: Yes

NO_LOCATION_VALUES_FOUND - No Location values have been found.

Data type:
Optional: No
Call by Reference: Yes

NO_PARTNER_PROFILE - No Partner profile could be determined.

Data type:
Optional: No
Call by Reference: Yes

NO_RNBT_FOR_PROCID - No business type was found for the specified process ID.

Data type:
Optional: No
Call by Reference: Yes

NO_ENTRY_IN_T683S - No entry was found in T683S.

Data type:
Optional: No
Call by Reference: Yes

NO_ENTRY_IN_T685A - No entry was found in T685A.

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for OIRE_GET_KALSM 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_e_kalsm  TYPE T683-KALSM, "   
lv_i_pblnr  TYPE OIREUPLKXXXX-PBLNR, "   
lt_ti_oira2_bbp1  TYPE STANDARD TABLE OF OIRA2_BBP1, "   
lv_pblnr_does_not_exist  TYPE OIRA2_BBP1, "   
lv_no_clearing_house_data  TYPE OIRA2_BBP1, "   
lv_neither_pblnr_nor_ch_passed  TYPE OIRA2_BBP1, "   
lv_e_kschl  TYPE T685A-KSCHL, "   
lv_i_chobj  TYPE OIRECH-CHOBJ, "   
lv_kalsm_does_not_exist  TYPE OIRECH, "   
lv_i_vkdat  TYPE OIREUPLKXXXX-VKDAT, "   
lv_no_pricing_procedure  TYPE OIREUPLKXXXX, "   
lv_i_vktim  TYPE OIREUPLKXXXX-VKTIM, "   
lv_no_kalvg_was_determined  TYPE OIREUPLKXXXX, "   
lv_i_procid  TYPE OIRAPROCDEF-PROCDEF, "   
lv_no_location_values_found  TYPE OIRAPROCDEF, "   
lv_i_ccins  TYPE OIREUPLKXXXX-SSR_CCINS, "   
lv_no_partner_profile  TYPE OIREUPLKXXXX, "   
lv_i_bukrs  TYPE T001-BUKRS, "   
lv_no_rnbt_for_procid  TYPE T001, "   
lv_i_kalvg  TYPE T683V-KALVG, "   
lv_no_entry_in_t683s  TYPE T683V, "   
lv_no_entry_in_t685a  TYPE T683V. "   

  CALL FUNCTION 'OIRE_GET_KALSM'  "Determine the pricing procedure from the business location
    EXPORTING
         I_PBLNR = lv_i_pblnr
         I_CHOBJ = lv_i_chobj
         I_VKDAT = lv_i_vkdat
         I_VKTIM = lv_i_vktim
         I_PROCID = lv_i_procid
         I_CCINS = lv_i_ccins
         I_BUKRS = lv_i_bukrs
         I_KALVG = lv_i_kalvg
    IMPORTING
         E_KALSM = lv_e_kalsm
         E_KSCHL = lv_e_kschl
    TABLES
         TI_OIRA2_BBP1 = lt_ti_oira2_bbp1
    EXCEPTIONS
        PBLNR_DOES_NOT_EXIST = 1
        NO_CLEARING_HOUSE_DATA = 10
        NEITHER_PBLNR_NOR_CH_PASSED = 11
        KALSM_DOES_NOT_EXIST = 2
        NO_PRICING_PROCEDURE = 3
        NO_KALVG_WAS_DETERMINED = 4
        NO_LOCATION_VALUES_FOUND = 5
        NO_PARTNER_PROFILE = 6
        NO_RNBT_FOR_PROCID = 7
        NO_ENTRY_IN_T683S = 8
        NO_ENTRY_IN_T685A = 9
. " OIRE_GET_KALSM




ABAP code using 7.40 inline data declarations to call FM OIRE_GET_KALSM

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 KALSM FROM T683 INTO @DATA(ld_e_kalsm).
 
"SELECT single PBLNR FROM OIREUPLKXXXX INTO @DATA(ld_i_pblnr).
 
 
 
 
 
"SELECT single KSCHL FROM T685A INTO @DATA(ld_e_kschl).
 
"SELECT single CHOBJ FROM OIRECH INTO @DATA(ld_i_chobj).
 
 
"SELECT single VKDAT FROM OIREUPLKXXXX INTO @DATA(ld_i_vkdat).
 
 
"SELECT single VKTIM FROM OIREUPLKXXXX INTO @DATA(ld_i_vktim).
 
 
"SELECT single PROCDEF FROM OIRAPROCDEF INTO @DATA(ld_i_procid).
 
 
"SELECT single SSR_CCINS FROM OIREUPLKXXXX INTO @DATA(ld_i_ccins).
 
 
"SELECT single BUKRS FROM T001 INTO @DATA(ld_i_bukrs).
 
 
"SELECT single KALVG FROM T683V INTO @DATA(ld_i_kalvg).
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!