Ansicht
Dokumentation
/SCTM/BAPI_SCHEDULE_SAVE_MULTI - BAPI FM for Creating, Changing, and Deleting Several Schedules
TXBHW - Original Tax Base Amount in Local Currency ABAP Short ReferenceThis documentation is copyright by SAP AG.
Functionality
The schedule data for a business system group, whose ID is transferred using 'LOG_SYSTEM' and 'BU_SYSTEM_GROUP', is copied from the value tables 'SCHEDULEHD' (header data), 'SCHEDULE_STOP' (stops), 'SCHEDULE_CAL' (departure calendar), 'SCHEDULE_TSP' (transportation service provider), and 'SCHEDULE_DEPT_TIME' (Concrete Departures). This occurs on the basis of the indicators set in the flag tables 'SCHEDULE_HD_X', 'SCHEDULE_STOP_X', 'SCHEDULE_CAL_X', 'SCHEDULE_TSP_X', and 'SCHEDULE_DEPT_TIME_X' and on the basis of the language transferred in 'LANGUAGE'.
Example
Entries in fields that have not been mentioned are not required for the example.
Header Data
Table 'SCHEDULE_HD'
LEG_ID_EXT: 'TEST_LEG'
LEG_DESCR: 'BAPI Test'
VAL_FROM_DATE: 01.01.2000
VAL_TO_DATE: 31.12.2007
MTR_ID: '0001'
The entry in field 'MTR_ID' must correspond to the ID of a means of transport that exists in the target system.
Flag table 'SCHEDULE_HD_X'
LEG_ID_EXT: 'TEST_LEG'
MODE: '1'
LEG_DESCR: 'X'
MTR_ID: 'X'
VALIDITY: 'X'
Stop Data
Table 'SCHEDULE_STOP'
LEG_ID_EXT: 'TEST_LEG'
SEQ_NUM: 00000
LOC_ID_EXT: 'BAPI_LOC1'
LOC_TYPE: '1001'
LOC_BSG: 'BSG1'
LEG_ID_EXT: 'TEST_LEG'
SEQ_NUM: 00001
LOC_ID_EXT: 'BAPI_LOC2'
LOC_TYPE: '1001'
LOC_BSG: 'BSG1'
The entries in the fields 'LOC_ID_EXT', 'LOC_' (location type), and 'LOC_BSG' must correspond to the ID of a location that exists in the target system.
Flag table 'SCHEDULE_STOP_X'
LEG_ID_EXT: 'TEST_LEG'
SEQ_NUM: 00000
MODE: '1'
STOP_ID_EXT: 'X'
LEG_ID_EXT: 'TEST_LEG'
SEQ_NUM: 00001
MODE: '1'
STOP_ID_EXT: 'X'
Transportation Service Provider Data
Table 'SCHEDULE_TSP'
LEG_ID_EXT: 'TEST_LEG'
MTR_ID: 0001
TSP_ID_EXT: 'TEST_TSP1'
VAL_FROM_DATE: '01.01.2007'
VAL_TO_DATE: '31.12.2007'
The entries in the fields 'MTR_ID' and 'TSP_ID_EXT' must correspond to the ID of a means of transport and a transportation service provider that exist in the target system.
Table 'SCHEDULE_TSP_X'
LEG_ID_EXT: 'TEST_LEG'
MTR_ID: 0001
TSP_ID_EXT: 'TEST_TSP1'
MODE: '1'
VALIDITY: 'X'
Calendar Assignment Data
Table 'SCHEDULE_TSP'
LEG_ID_EXT: 'TEST_LEG'
MTR_ID: 0001
VEHICLE_ID_EXT: 'VEHILCE_1'
VEHICLE_BSG: 'BSG1'
DEPART_CAL_ID: 'TEST_CAL'
Flag table 'SCHEDULE_CAL_X'
LEG_ID_EXT: 'TEST_LEG'
MTR_ID: 0001
VEHICLE_ID_EXT: 'VEHICLE_1'
MODE: '1'
DEPART_CAL_ID: 'X'
Schedule Departure Data
Table 'SCHEDULE_DEPT_TIME'
LEG_ID_EXT: 'TEST_LEG'
DEPART_CAL_ID: 'TEST_CAL'
DEPART_DATE: '02.04.2007'
DEPART_TIME: '11:00'
DEPART_FIX: 'X'
Flag table 'SCHEDULE_DEPT_TIME_X'
LEG_ID_EXT: 'TEST_LEG'
DEPART_CAL_ID: 'TEST_CAL'
DEPART_DATE: 'X'
DEPART_TIME: 'X'
DEPART_FIX: 'X'
MODE: '1'
Notes
1. An entry in the relevant flag table must be available for each entry in a value table.
2. It is mandatory to specify the logical system 'LOG_SYSTEM'. Optionally, you can specify the business system group 'BU_SYSTEM_GROUP'.
3. A schedule can only be created (mode = '1') if at least two corresponding entries exist in the stop table 'SCHEDULE_STOP' for each entry in the header data table 'SCHEDULE_HD'. These two entries are the start stop and the destination stop of the schedule.
4. The stop sequence must be complete when creating, adding, and deleting stops.
5 . You can make changes only to the attributes of individual stops. The change mode for all specified stops must be the same.
6. The data to be changed is not updated until after a commit. This is not executed in the function module.
7. The following modes are possible in the flag tables:
Add '1'
Change '2'
Maintain (Add or Change) '3'
Delete '4'
The mode 'Maintain' allows you to specify the required end state on the database without it being known whether data already exists that is to be overwritten or whether new data must be added.
8. In the data table 'SCHEDULE_DEPT_TIME' the time zone field must be provided. If not provided, the BADI assumes the time zone is UTC.
Further information
Parameters
BU_SYSTEM_GROUPLANGUAGE
LOG_SYSTEM
RETURN
SCHEDULE_CAL
SCHEDULE_CAL_X
SCHEDULE_DEPT_TIME
SCHEDULE_DEPT_TIME_X
SCHEDULE_HD
SCHEDULE_HD_X
SCHEDULE_STOP
SCHEDULE_STOP_X
SCHEDULE_TSP
SCHEDULE_TSP_X
Exceptions
Function Group
M/SAPLBAPI_LEGFill RESBD Structure from EBP Component Structure BAL_S_LOG - Application Log: Log header data
This documentation is copyright by SAP AG.
Length: 6855 Date: 20240419 Time: 164847 sap01-206 ( 91 ms )