SAP OIJ_GET_PREV_SSC_DATA Function Module for Get Previous SSC Data
OIJ_GET_PREV_SSC_DATA is a standard oij get prev ssc data SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Get Previous SSC Data 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 oij get prev ssc data FM, simply by entering the name OIJ_GET_PREV_SSC_DATA into the relevant SAP transaction such as SE37 or SE38.
Function Group: OIJ_SS
Program Name: SAPLOIJ_SS
Main Program: SAPLOIJ_SS
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function OIJ_GET_PREV_SSC_DATA 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 'OIJ_GET_PREV_SSC_DATA'"Get Previous SSC Data.
EXPORTING
IV_VEHICLE = "TD Vehicle Number
IV_LOCID = "Location ID
IV_PEGID = "TSW: Pegging identifier
* IV_BYPASS_BUFFER = "boolean variable (X=true, -=false, space=unknown)
* IV_REFRESH_BUFFER = "boolean variable (X=true, -=false, space=unknown)
IMPORTING
ES_PR_SSC_DATA = "Previous Visit Data
EV_VOYAGE_COUNTER = "Voyage Counter
ES_PR_CR_CALC_DATA = "Data for the current Visit
EXCEPTIONS
NO_DATA_FOUND = 1 VEHICLE_MISSING = 2 LOCID_MISSING = 3 PEGID_MISSING = 4
IMPORTING Parameters details for OIJ_GET_PREV_SSC_DATA
IV_VEHICLE - TD Vehicle Number
Data type: OIG_VHLNMROptional: No
Call by Reference: No ( called with pass by value option)
IV_LOCID - Location ID
Data type: OIJ_LOCIDOptional: No
Call by Reference: No ( called with pass by value option)
IV_PEGID - TSW: Pegging identifier
Data type: OIJ_PEGIDOptional: No
Call by Reference: No ( called with pass by value option)
IV_BYPASS_BUFFER - boolean variable (X=true, -=false, space=unknown)
Data type: BOOLEANOptional: Yes
Call by Reference: No ( called with pass by value option)
IV_REFRESH_BUFFER - boolean variable (X=true, -=false, space=unknown)
Data type: BOOLEANOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for OIJ_GET_PREV_SSC_DATA
ES_PR_SSC_DATA - Previous Visit Data
Data type: OIJ_VEH_PERFOptional: No
Call by Reference: Yes
EV_VOYAGE_COUNTER - Voyage Counter
Data type: OIJ_VOYAGE_COUNTEROptional: No
Call by Reference: Yes
ES_PR_CR_CALC_DATA - Data for the current Visit
Data type: OIJ_VEH_PERFOptional: No
Call by Reference: Yes
EXCEPTIONS details
NO_DATA_FOUND - No Data Found
Data type:Optional: No
Call by Reference: Yes
VEHICLE_MISSING - Vehicle Is Missing
Data type:Optional: No
Call by Reference: Yes
LOCID_MISSING - Location Is Missing
Data type:Optional: No
Call by Reference: Yes
PEGID_MISSING - Peg ID Is Missing
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for OIJ_GET_PREV_SSC_DATA 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_iv_vehicle | TYPE OIG_VHLNMR, " | |||
| lv_no_data_found | TYPE OIG_VHLNMR, " | |||
| lv_es_pr_ssc_data | TYPE OIJ_VEH_PERF, " | |||
| lv_iv_locid | TYPE OIJ_LOCID, " | |||
| lv_vehicle_missing | TYPE OIJ_LOCID, " | |||
| lv_ev_voyage_counter | TYPE OIJ_VOYAGE_COUNTER, " | |||
| lv_iv_pegid | TYPE OIJ_PEGID, " | |||
| lv_locid_missing | TYPE OIJ_PEGID, " | |||
| lv_es_pr_cr_calc_data | TYPE OIJ_VEH_PERF, " | |||
| lv_pegid_missing | TYPE OIJ_VEH_PERF, " | |||
| lv_iv_bypass_buffer | TYPE BOOLEAN, " | |||
| lv_iv_refresh_buffer | TYPE BOOLEAN. " |
|   CALL FUNCTION 'OIJ_GET_PREV_SSC_DATA' "Get Previous SSC Data |
| EXPORTING | ||
| IV_VEHICLE | = lv_iv_vehicle | |
| IV_LOCID | = lv_iv_locid | |
| IV_PEGID | = lv_iv_pegid | |
| IV_BYPASS_BUFFER | = lv_iv_bypass_buffer | |
| IV_REFRESH_BUFFER | = lv_iv_refresh_buffer | |
| IMPORTING | ||
| ES_PR_SSC_DATA | = lv_es_pr_ssc_data | |
| EV_VOYAGE_COUNTER | = lv_ev_voyage_counter | |
| ES_PR_CR_CALC_DATA | = lv_es_pr_cr_calc_data | |
| EXCEPTIONS | ||
| NO_DATA_FOUND = 1 | ||
| VEHICLE_MISSING = 2 | ||
| LOCID_MISSING = 3 | ||
| PEGID_MISSING = 4 | ||
| . " OIJ_GET_PREV_SSC_DATA | ||
ABAP code using 7.40 inline data declarations to call FM OIJ_GET_PREV_SSC_DATA
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.Search for further information about these or an SAP related objects