SAP FITP_CREATE_SAVE_EMPTY_PLAN Function Module for Creation and saving of an empty plan/trip
FITP_CREATE_SAVE_EMPTY_PLAN is a standard fitp create save empty plan SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Creation and saving of an empty plan/trip 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 fitp create save empty plan FM, simply by entering the name FITP_CREATE_SAVE_EMPTY_PLAN into the relevant SAP transaction such as SE37 or SE38.
Function Group: FITP_PLAN
Program Name: SAPLFITP_PLAN
Main Program: SAPLFITP_PLAN
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function FITP_CREATE_SAVE_EMPTY_PLAN 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 'FITP_CREATE_SAVE_EMPTY_PLAN'"Creation and saving of an empty plan/trip.
EXPORTING
I_PERNR = "Personnel Number
PLAN_START_DATE = "Beginning date of travel plan
* PLAN_START_TIME = '000000' "Beginning time of travel plan
PLAN_END_DATE = "End date of travel plan
* PLAN_END_TIME = '000000' "End time of travel plan
IMPORTING
O_REINR = "Trip number
EXCEPTIONS
PERNR_DOES_NOT_EXIST = 1 REINR_NOT_CREATED = 2
IMPORTING Parameters details for FITP_CREATE_SAVE_EMPTY_PLAN
I_PERNR - Personnel Number
Data type: FTPT_PLAN-PERNROptional: No
Call by Reference: Yes
PLAN_START_DATE - Beginning date of travel plan
Data type: FTPT_PLAN-DATE_BEGOptional: No
Call by Reference: Yes
PLAN_START_TIME - Beginning time of travel plan
Data type: FTPT_PLAN-TIME_BEGDefault: '000000'
Optional: No
Call by Reference: Yes
PLAN_END_DATE - End date of travel plan
Data type: FTPT_PLAN-DATE_ENDOptional: No
Call by Reference: Yes
PLAN_END_TIME - End time of travel plan
Data type: FTPT_PLAN-TIME_ENDDefault: '000000'
Optional: No
Call by Reference: Yes
EXPORTING Parameters details for FITP_CREATE_SAVE_EMPTY_PLAN
O_REINR - Trip number
Data type: FTPT_PLAN-REINROptional: No
Call by Reference: Yes
EXCEPTIONS details
PERNR_DOES_NOT_EXIST - Personal Number not found in database
Data type:Optional: No
Call by Reference: Yes
REINR_NOT_CREATED - The Trip number could not be generated
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for FITP_CREATE_SAVE_EMPTY_PLAN 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_i_pernr | TYPE FTPT_PLAN-PERNR, " | |||
| lv_o_reinr | TYPE FTPT_PLAN-REINR, " | |||
| lv_pernr_does_not_exist | TYPE FTPT_PLAN, " | |||
| lv_plan_start_date | TYPE FTPT_PLAN-DATE_BEG, " | |||
| lv_reinr_not_created | TYPE FTPT_PLAN, " | |||
| lv_plan_start_time | TYPE FTPT_PLAN-TIME_BEG, " '000000' | |||
| lv_plan_end_date | TYPE FTPT_PLAN-DATE_END, " | |||
| lv_plan_end_time | TYPE FTPT_PLAN-TIME_END. " '000000' |
|   CALL FUNCTION 'FITP_CREATE_SAVE_EMPTY_PLAN' "Creation and saving of an empty plan/trip |
| EXPORTING | ||
| I_PERNR | = lv_i_pernr | |
| PLAN_START_DATE | = lv_plan_start_date | |
| PLAN_START_TIME | = lv_plan_start_time | |
| PLAN_END_DATE | = lv_plan_end_date | |
| PLAN_END_TIME | = lv_plan_end_time | |
| IMPORTING | ||
| O_REINR | = lv_o_reinr | |
| EXCEPTIONS | ||
| PERNR_DOES_NOT_EXIST = 1 | ||
| REINR_NOT_CREATED = 2 | ||
| . " FITP_CREATE_SAVE_EMPTY_PLAN | ||
ABAP code using 7.40 inline data declarations to call FM FITP_CREATE_SAVE_EMPTY_PLAN
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 PERNR FROM FTPT_PLAN INTO @DATA(ld_i_pernr). | ||||
| "SELECT single REINR FROM FTPT_PLAN INTO @DATA(ld_o_reinr). | ||||
| "SELECT single DATE_BEG FROM FTPT_PLAN INTO @DATA(ld_plan_start_date). | ||||
| "SELECT single TIME_BEG FROM FTPT_PLAN INTO @DATA(ld_plan_start_time). | ||||
| DATA(ld_plan_start_time) | = '000000'. | |||
| "SELECT single DATE_END FROM FTPT_PLAN INTO @DATA(ld_plan_end_date). | ||||
| "SELECT single TIME_END FROM FTPT_PLAN INTO @DATA(ld_plan_end_time). | ||||
| DATA(ld_plan_end_time) | = '000000'. | |||
Search for further information about these or an SAP related objects