36
CS-SDL Interface (CS-SE-SD) Release 46C

CS-SDL Interface (CS-SE-SD) - SAP

  • Upload
    others

  • View
    15

  • Download
    0

Embed Size (px)

Citation preview

Page 1: CS-SDL Interface (CS-SE-SD) - SAP

CS-SDL Interface (CS-SE-SD)

Release 46C

Page 2: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 1

Copyright

© Copyright 2000 SAP AG. All rights reserved.

No part of this brochure may be reproduced or transmitted in any form or for any purposewithout the express permission of SAP AG. The information contained herein may bechanged without prior notice.

Some software products marketed by SAP AG and its distributors contain proprietarysoftware components of other software vendors.

Microsoft®, WINDOWS®, NT®, EXCEL®, Word® and SQL-Server® are registeredtrademarks of Microsoft Corporation.

IBM®, DB2®, OS/2®, DB2/6000®, Parallel Sysplex®, MVS/ESA®, RS/6000®, AIX®, S/390®,AS/400®, OS/390®, and OS/400® are registered trademarks of IBM Corporation.

OSF/Motif® is a registered trademark of Open Software Foundation.

ORACLE® is a registered trademark of ORACLE Corporation, California, USA.

INFORMIX®-OnLine for SAP is a registered trademark of Informix Software Incorporated.

UNIX®, X/Open®, OSF/1®, and Motif® are registered trademarks of the Open Group.

ADABAS® is a registered trademark of Software AG.

SAP and SAP-Logo, R/2, R/3, RIVA, ABAP, SAP-EDI, SAP Business Workflow, SAPEarlyWatch, SAP ArchiveLink, ALE/WEB, BAPI, SAPPHIRE, Management Cockpit, SEM, aretrademarks or registered trademarks of SAP AG in Germany and in several other countries allover the world.

Icons

Icon Meaning

Caution

Example

Note

Recommendation

Syntax

Tip

Page 3: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 2

CS-SDL Interface (CS-SE-SD) ..............................................................................................3

External Scheduling ...........................................................................................................5

External Scheduling in the Order ....................................................................................8

External Scheduling in the Completion Confirmation .....................................................10

External Scheduling in Maintenance Planning...............................................................11

External Scheduling in the Graphical Monitor................................................................13

Notes on Function Modules..............................................................................................14

Function Module PM_ORDER_EXTERN_SCHED_DIALOG .........................................17

Function Module PM_ORDER_EXTERN_SCHED_DEFAULT ......................................20

Function Module PM_ORDER_EXTERN_SCHED_APPOINT.......................................24

Function Module PM_ORDER_EXTERN_BOOK_DEFAULT.........................................28

Function Module READ_WORKLOAD ..........................................................................31

Function Module PM_ORDER_EXTERN_MASTER_DATA...........................................33

Scheduling an Order Externally........................................................................................35

Page 4: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 3

CS-SDL Interface (CS-SE-SD)

PurposeYou can use the CS-SDL interface to perform interactive scheduling for orders and fieldservice planning with an external scheduling system. In the SAP System, the data is saved inthe order and can be used by the application components Plant Maintenance (PM) andCustomer Service (CS). The additional functions in comparison to the capacity planningfunction in the SAP System depend on the respective scheduling system.

Implementation ConsiderationsIf the scheduling functions in the SAP System are not sufficient for your field servicesplanning, the CS-SDL interface enables you to use an external scheduling system.

You can implement the CS-SDL interface in the following ways:

• You use a partner solution. A prerequisite for this is that you have performed all thenecessary Customizing settings [Seite 5].

• You program your own solution.

SAP delivers function modules that you can use for a scheduling agreement dialog fordetermining dates.

The function module PM_ORDER_EXTERN_SCHED_DIALOG [Seite 17] delivers the dialogand calls up the interface PM_ORDER_EXTERN_SCHED_APPOINT [Seite 24]. This resultsin the scheduling data being copied from the external scheduling system during orderscheduling.

You will find more information on certified products in SAPNet under Customers& Partners → Partners → Complementary Software Program.

The implementation of external systems is not supported by SAP consultants,and the technical prerequisites for the external product must be agreed upon withcompetent consultants for the external system.

FeaturesThe following scenarios are supported with this component:

• Finite scheduling

You have a work center with five capacities of 40 hours per week each in yourcompany. The external scheduling system checks the dates and schedules on thebasis of capacity and not on the basis of individual technicians.

• Field services planning

The external system performs checks and schedules on the basis of individualtechnicians.

If you use the external scheduling system for finite scheduling, the SAP System frontend isinsufficient. If you want to use field services planning in the form of a planning board, yourequire the external scheduling system as an additional frontend.

ConstraintsThe following functions are not supported:

• Time dependency or operational constraints (obligatory/optional/start/end)

• SAP planning board

Page 5: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 4

• Changes to the order data in the external scheduling system are not updated in the SAPSystem.

Page 6: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 5

External Scheduling

PurposeYou use the external scheduling function in your company to plan field services using anexternal system.

PrerequisitesThe following prerequisites must be met:

• You have defined the order types for which you want to activate external scheduling inCustomizing under Plant Maintenance and Customer Service → Maintenance andService Processing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Define for Each Order.

• You have performed the settings for the external scheduling of the order in Customizingunder Plant Maintenance and Customer Service → Maintenance and Service Processing→ Maintenance and Service Orders → Scheduling → External Scheduling → ConfigureCommunication.

For more information on configuring communication, see the Implementation Guide(IMG) under Plant Maintenance and Customer Service → Maintenance and ServiceProcessing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Configure Communication.

• You have configured the scheduling parameters for external scheduling in Customizingunder Plant Maintenance and Customer Service → Maintenance and Service Processing→ Maintenance and Service Orders → Scheduling → External Scheduling → SetExternal Scheduling Parameters.

• You have studied the basics of remote function calls [Extern] and transactional remotefunction calls.

For more information on Remote Function Calls, see the SAP Library under BasisComponents → Basis Services/Communication Interfaces (BC-SRV) → RemoteCommunications (BC-SRV-RC) → The RFC API.

Process Flow1. You create an order and have agreed a start and finish date for the order with the

customer. It is obvious from the problem description which tasks must be performed. Youcan maintain the partner manually in the order header. The system uses the partnerfunction that you have maintained in Customizing in the function Maintain CapacityRequirements to propose the technician you want to perform the tasks. If there is morethan one partner for this partner function, the system always copies the first partner.

For more information on the settings for partners in Customizing, see Customizing forPartners [Extern].

2. If you have assigned the function modules PM_ORDER_EXTERN_SCHED_DEFAULT[Seite 20] or PM_ORDER_EXTERN_SCHED_DIALOG [Seite 17] to the fixed values S orD when configuring communication in Customizing, the system finds a suitable date in theexternal system using the interface. The SAP system does not save the dates at thispoint. This first occurs when you save the order. The value "Work" is used at the interfacefor the effort required. Bi-directional communication occurs with the external system.

3. You schedule the order using Order → Functions → Dates → Schedule. The systemupdates the order using the scheduling agreements from the external scheduling systemand sets the system status EXTM (scheduling by external system). The dates are passedon to reservation, purchase request, and so on.

Page 7: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 6

4. If you have assigned the function module PM_ORDER_EXTERN_BOOK_DEFAULT[Seite 28] to the fixed value B when configuring communication in Customizing, the SAPSystem transfers the dates to the external scheduling system when you save the order sothat the dates are available in both systems.

5. The SAP System shows you how resources are distributed in the external schedulingsystem by means of the graphical monitor [Extern]. This is only possible if scheduling isperformed for individual technicians.

Depending on which application component you are working in, choose

• Logistics → Plant Maintenance → Maintenance Processing → Capacity RequirementsPlanning → Graphical Monitor

• Logistics → Customer Service → Service Processing → Order → Capacity Planning →Graphical Monitor

The External Scheduling Process from a Business Management Viewpoint

Create orderLook for suitable

date

Update order

Save order

ResultBi-directional communication between the SAP System and the external system by means ofthe CS-SDL interface [Extern]. The external system finds a suitable date and returns it to theSAP System.

The information from the final confirmation that the task is completed is transferred to theexternal scheduling system as well as to the status information. The final confirmation of anoperation, such as order completion for example, causes a reduction in requirements in theexternal scheduling system.

The SAP System forwards the following system statuses to the external scheduling system:

• Created

• Released

• Completed

• Locked

No distinction is made between technical and business completion. The SAP System sets thestatus Completed for the function Do not execute order.

Page 8: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 7

The status can be either Created, Released, Completed, or Locked.

You can perform changes to the basic dates of the order and operation dates using thefunction Change order, as all the information on the order is available here.

Changes to the order data in the external scheduling system are not updated in the SAPSystem. However, you can display the actual situation of the external scheduling systemusing the graphical monitor in the SAP System.

If you change and schedule an order, the SAP System displays proposed dates from theexternal scheduling system for the modified dates.

If you perform changes to the dates in the SAP System or save the dates, the new dates aretransferred to the external scheduling system. The dates are posted and any capacityproblems displayed in the external scheduling system.

Page 9: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 8

External Scheduling in the Order

UseYou use this function in order processing in your company to plan field services using anexternal scheduling system.

PrerequisitesFor more information on the prerequisites, see External Scheduling [Seite 5].

Features• You create an order in the SAP System and schedule it.

• If you have assigned the function module PM_ORDER_EXTERN_SCHED_DIALOG[Seite 17] to the fixed value D in Customizing under Configure Communication, andentered the external scheduling system as the destination, the dialog box Schedulingagreement appears after the order has been scheduled.

• You enter your desired dates and select proposed dates.

• If you have assigned the function module PM_ORDER_EXTERN_SCHED_APPOINT[Seite 24] to the fixed value A in Customizing, the system calls the function modulePM_ORDER_EXTERN_SCHED_APPOINT after you have selected the pushbuttonProposed dates.

• The external system looks for a suitable date, and the function modulePM_ORDER_EXTERN_SCHED_APPOINT is called up again.

• The SAP System proposes a list of dates, you select the most suitable ones, and returnto the order processing screen.

• After you have saved the order, the system calls up the function modulePM_ORDER_EXTERN_BOOK_DEFAULT [Seite 28].

• The system transfers the data asynchronously to the external scheduling system usingtransactional remote function calls. The dates are posted in the SAP System and in theexternal system.

The External Scheduling Process from a Technical Viewpoint

Page 10: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 9

Function modulePM_ORDER_EXTERN_SCHED_APPOINT

Function module PM_ORDER_EXTERN_BOOK_DEFAULT

Dates are posted in the SAP System and in the external system

Function modulePM_ORDER_EXTERN_SCHED_DIALOG

Function modulePM_ORDER_EXTERN_SCHED_APPOINT

Create order

Schedule order Dialog box Date agreement

is displayed

External system looks for date

Date sequence proposalsare displayed

Save order

Change order

Page 11: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 10

External Scheduling in the Completion Confirmation

UseYou use this function in the completion confirmation in your company to plan field servicesusing an external system.

PrerequisitesFor more information on the prerequisites, see External Scheduling [Seite 5].

You have assigned the function module PM_ORDER_EXTERN_BOOK_DEFAULT to thefixed value B in Customizing under Plant Maintenance and Customer Service → Maintenanceand Service Processing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Configure Communication.

FeaturesIf you finally confirm an operation, the SAP System calls up the function modulePM_ORDER_EXTERN_BOOK_DEFAULT [Seite 28] and sets the update indicator of theoperation to C for 'Finally confirmed'.

In the external scheduling system, the operation must be set to Completed orelse deleted after this function has been called.

Function module PM_ORDER_EXTERN_BOOK_DEFAULTUpdate indicator ‘Finally confirmed’ set.

Function modulePM_ORDER_EXTERN_SCHED_DEFAULT

Order changed

Order savedautomatically

Comp. confirmation

External system setsoperation to‘Completed’

Page 12: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 11

External Scheduling in Maintenance Planning

UseYou use this function in maintenance planning in your company to plan field services using anexternal scheduling system.

PrerequisitesYou have performed the following settings in Customizing:

• You have assigned the function module PM_ORDER_EXTERN_SCHED_DEFAULT[Seite 20] to the fixed value S in Customizing under Plant Maintenance and CustomerService → Maintenance and Service Processing → Maintenance and Service Orders →Scheduling → External Scheduling → Configure Communication.

• You have set the indicator Release immediately in Customizing under Plant Maintenanceand Customer Service → Maintenance and Service Processing → Maintenance andService Orders → Function and Settings for Order Types → Configure Order Types.

• You have set the indicator Automatic scheduling in Customizing under Plant Maintenanceand Customer Service → Maintenance and Service Processing → Maintenance andService Orders→ Scheduling → Set Scheduling Parameters.

FeaturesIf you generate an order from the maintenance plan, the SAP System calls up the functionmodule PM_ORDER_EXTERN_SCHED_DEFAULT.

Depending on the Customizing settings, scheduling automatically takes places in the externalscheduling system. The external system looks for a suitable date and returns this to the orderin the SAP System.

The SAP System saves the order and calls up the function modulePM_ORDER_EXTERN_BOOK_DEFAULT [Seite 28].

The date is automatically posted in the SAP System and in the external scheduling system.

There is no dialog, and there are no proposed dates from which you can choose a suitabledate.

External Scheduling in Maintenance Planning

Page 13: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 12

Function modulePM_ORDER_EXTERN_BOOK_DEFAULT

Function modulePM_ORDER_EXTERN_SCHED_DEFAULT

Generate order from

maintenance plan

External system looks for date

Order savedautomatically

Maintenance planning

Date posted inexternal system

Page 14: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 13

External Scheduling in the Graphical Monitor

UseThe SAP System uses the graphical monitor [Extern] to display the distribution of resourceseither in the external scheduling system or in the SAP System itself. This is only possible ifscheduling is performed for individual technicians.

PrerequisitesYou have assigned the function module READ_WORKLOAD [Seite 31] to the fixed value R inCustomizing under Plant Maintenance and Customer Service → Maintenance and ServiceProcessing → Maintenance and Service Orders → Scheduling → External Scheduling →Configure Communication.

This function module defines the interface that reads the actual dates for the technician fromthe external scheduling system when the graphical monitor is started or refreshed.

Activities1. Depending on which application component you are working in, choose

• Logistics → Plant Maintenance → Maintenance Processing → Capacity RequirementsPlanning → Graphical Monitor

• Logistics → Customer Service → Service Processing → Order → Capacity Planning →Graphical Monitor

2. Set the indicator External in the screen area Scheduling.

3. The system displays the current field service planning dates from the external schedulingsystem in the graphical monitor.

Page 15: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 14

Notes on Function Modules

UseThe following function modules define the technical part of the CS-SDL interface.

The export parameters, import parameters, and interface tables are defined in these functionmodules. You also find the fields and structures that are used.

As an SAP customer, you require the function modules if you want to program your ownsystem.

As an SAP partner, you require the function modules in order to be certified for this interface.

The following function modules for current communication with the external schedulingsystem are delivered with the CS-SDL interface:

• PM_ORDER_EXTERN_BOOK_DEFAULT [Seite 28]

• PM_ORDER_EXTERN_SCHED_APPOINT [Seite 24]

• PM_ORDER_EXTERN_SCHED_DEFAULT [Seite 20]

• PM_ORDER_EXTERN_SCHED_DIALOG [Seite 17]

• READ_WORKLOAD [Seite 31]

The following function module is used for reading master data from the SAP System to theexternal scheduling system.

• PM_ORDER_EXTERN_MASTER_DATA [Seite 33]

ActivitiesNotes on individual parameter components that are used in all function modules and whichyou must take into account when implementing an external scheduling system:

ParameterName

Component Data Type Length Short Text

ORDER_

HEADER

ORDER_

NUMBER

CHAR 12 Order number

The component ORDER_NUMBER is the key field of the order.

ParameterName

Component Data Type Length Short Text

ORDER_

HEADER

OWN_LOGICAL_SYSTEM

CHAR 10 Logical system

If a logical system has been defined in the SAP System, it will be made available to you in thiscomponent. Use of this system is optional.

ParameterName

Component Data Type Length Short Text

Page 16: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 15

ORDER_

HEADER

PREFERRED_

ENGINEER

NUMC 8 Object ID

Depending on the partner settings in Customizing, this component places the desiredtechnician at your disposal.

ParameterName

Component Data Type Length Short Text

ORDER_

HEADER

STATUS CHAR 4 Individual objectstatus (shortform)

This component informs you of the system status. The following fixed values are possible:

• CRTD = created (Order created)

• REL = released (Order released)

• CLSD = completed (Order completed)

• LKD = locked (Order locked)

ParameterName

Component Data Type Length Short Text

OPERATIONS ID NUMC 8 General counterfor the order

The component ID is the key field for the operation.

ParameterName

Component Data Type Length Short Text

OPERATIONS SUB_COUNTER CHAR 4 Sub-operation

This component is active, but will not be transferred to the interface in Release 4.6C. Onlyoperations and no sub-operations will be transferred to the interface.

ParameterName

Component Data Type Length Short Text

OPERATIONS UPDATE_FLAG CHAR 1 Update indicator

This component has the following fixed values:

• I = insert (Insert operation)

• U = update (Update operation)

• C = confirm (Finally confirm operation)

• D = delete (Delete operation)

Error Handling

There are two ways of dealing with errors:

1. You can use the exceptions defined in the function modules. The SAP System displaysan error message if these exceptions are triggered.

Page 17: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 16

2. If you use the parameters ERROR_CODE and ERROR_DESCRIPTION, the SAPSystem displays these two parameters as an error message to the end user.

Page 18: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 17

Function ModulePM_ORDER_EXTERN_SCHED_DIALOG

UseThis function module is a component of the CS-SDL interface [Extern] with which an externalscheduling system can be connected to the order processing function in the application areasPlant Maintenance and Customer Service.

IntegrationThe function module PM_ORDER_EXTERN_SCHED_DIALOG shows you how a dialog inwhich dates can be selected is also possible if the function modulePM_ORDER_EXTERN_SCHED_DEFAULT [Seite 20] is used instead of automaticscheduling.

PrerequisitesYou have assigned the function module PM_ORDER_EXTERN_SHED_DIALOG to the fixedvalue D in Customizing under Plant Maintenance and Customer Service → Maintenance andService Processing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Configure Communication.

Features

Import Parameters

Parameter Name Component Data Type Length

Short Text

ORDER_

NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

STREET CHAR 35 Street and house number

ORDER_HEADER

STATUS CHAR 4 Individual object status(short form)

Page 19: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 18

DIALOG_

POSSIBLE

CHAR 1 One-character indicator

Export Parameters

Parameter Name Component Data Type Length

Short Text

ORDER_

NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_

NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

STREET CHAR 35 Street and house number

ORDER_HEADER_RETURN

STATUS CHAR 4 Individual object status(short form)

ERROR_CODE NUMC 4 Counter parameters

ERROR_

DESCRIPTION

CHAR 70 Character field of list 70

Tables

Parameter Name Component Data Type Length

Short Text

ID NUMC 8 General counter for theorder

COUNTER CHAR 4 Operation number

SUB_COUNTER CHAR 4 Sub-operation

UPDATE_FLAG CHAR 1 Update indicator

OPERATIONS

DESCRIPTION CHAR 40 Operation short text

Page 20: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 19

EARLIEST_

START_DATE

DATS 8 Earliest scheduled start:Execute (date)

EARLIEST_

START_TIME

TIMS 6 Earliest scheduled start:Execute (time)

LATEST_START_DATE

DATS 8 Latest scheduled start:Execute (date)

LATEST_START_TIME

TIMS 6 Latest scheduled start:Execute (time)

EARLIEST_

FINISH_DATE

DATS 8 Earliest scheduled finish:Execute (date)

EARLIEST_

FINISH_TIME

TIMS 6 Earliest scheduled finish:Execute (time)

LATEST_FINISH_DATE

DATS 8 Latest scheduled finish:Execute (date)

LATEST_FINISH_TIME

TIMS 6 Latest scheduled finish:Execute (time)

NUMBER_OF_

CAPACITY

NUMC 2 Two-figure number

WORKCENTER CHAR 8 Work center

PLANT CHAR 4 Plant

AMOUNT_OF_

WORK

FLTP 16

SCHED_

PARAM1

CHAR 4 Scheduling parameters forexternal scheduling

SCHED_

PARAM2

CHAR 4 Scheduling parameters forexternal scheduling

SCHED_

PARAM3

CHAR 4 Scheduling parameters forexternal scheduling

REQUIREMENTS OPERATION_ID NUMC 8 General counter for theorder

QUALIFICATION_ID

NUMC 8 Object ID

RATING NUMC 4 Characteristics of a qualityscale

ESSENTIAL CHAR 1 Indicator: Mandatory oroptional requirement

Page 21: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 20

Function ModulePM_ORDER_EXTERN_SCHED_DEFAULT

UseThis function module is a component of the CS-SDL interface [Extern] with which an externalscheduling system can be connected to the order processing function in the application areasPlant Maintenance and Customer Service.

IntegrationThe system calls up this function module for the following functionality:

• When generating an order from maintenance planning

• During final confirmation

PrerequisitesYou have assigned the function module PM_ORDER_EXTERN_SCHED_DEFAULT to thefixed value S in Customizing under Plant Maintenance and Customer Service → Maintenanceand Service Processing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Configure Communication.

Features

Import Parameters

Parameter Name Component Data Type Length

Short Text

ORDER_

NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

STREET CHAR 35 Street and house number

ORDER_HEADER

STATUS CHAR 4 Individual object status(short form)

Page 22: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 21

DIALOG_

POSSIBLE

CHAR 1 One-character indicator

Export Parameters

Parameter Name Component Data Type Length

Short Text

ORDER_

NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_

NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

STREET CHAR 35 Street and house number

ORDER_HEADER_RETURN

STATUS CHAR 4 Individual object status(short form)

ERROR_CODE NUMC 4 Counter parameters

ERROR_

DESCRIPTION

CHAR 70 Character field of list 70

Tables

Parameter Name Component Data Type Length

Short Text

ID NUMC 8 General counter for theorder

COUNTER CHAR 4 Operation number

SUB_COUNTER CHAR 4 Sub-operation

OPERATIONS

UPDATE_

FLAG

CHAR 1 Update indicator

Page 23: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 22

DESCRIPTION CHAR 40 Operation short text

EARLIEST_

START_DATE

DATS 8 Earliest scheduled start:Execute (date)

EARLIEST_

START_TIME

TIMS 6 Earliest scheduled start:Execute (time)

LATEST_

START_DATE

DATS 8 Latest scheduled start:Execute (date)

LATEST_

START_TIME

TIMS 6 Latest scheduled start:Execute (time)

EARLIEST_

FINISH_DATE

DATS 8 Earliest scheduled finish:Execute (date)

EARLIEST_

FINISH_TIME

TIMS 6 Earliest scheduled finish:Execute (time)

LATEST_

FINISH_DATE

DATS 8 Latest scheduled finish:Execute (date)

LATEST_

FINISH_TIME

TIMS 6 Latest scheduled finish:Execute (time)

NUMBER_OF_CAPACITY

NUMC 2 Two-figure number

WORKCENTER CHAR 8 Work center

PLANT CHAR 4 Plant

AMOUNT_OF_WORK

FLTP 16

SCHED_

PARAM1

CHAR 4 Scheduling parameters forexternal scheduling

SCHED_

PARAM2

CHAR 4 Scheduling parameters forexternal scheduling

SCHED_

PARAM3

CHAR 4 Scheduling parameters forexternal scheduling

OPERATION_ID NUMC 8 General counter for theorder

QUALIFICATION_ID

NUMC 8 Object ID

RATING NUMC 4 Characteristics of a qualityscale

REQUIREMENTS

ESSENTIAL CHAR 1 Indicator: Mandatory oroptional requirement

Note

The operations to be scheduled are transferred to the interface in the table OPERATIONS.

After this function module has been called, the scheduled dates in the table OPERATIONS inthe components EARLIEST_START_DATE/TIME, LATEST_START_DATE/TIME,

Page 24: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 23

EARLIEST_FINISH_DATE/TIME, LATEST_FINISH_DATE/TIME must be transferred to theSAP System.

Page 25: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 24

Function ModulePM_ORDER_EXTERN_SCHED_APPOINT

UseThis function module is a component of the CS-SDL interface [Extern] with which an externalscheduling system can be connected to the order processing function in the applicationcomponents Plant Maintenance and Customer Service.

IntegrationThe function module PM_ORDER_EXTERN_SCHED_APPOINT defines the interface inorder to be able to select a suitable date from the different proposed dates delivered by theexternal scheduling system.

PrerequisitesYou are using the function module PM_ORDER_EXTERN_SCHED_DIALOG [Seite 17] andhave assigned the function module PM_ORDER_EXTERN_SCHED_APPOINT to the fixedvalue A in Customizing under Plant Maintenance and Customer Service → Maintenance andService Processing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Configure Communication.

Features

Import Parameters

Parameter Name Component Data Type Length Short Text

ORDER_NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

STREET CHAR 35 Street and house number

ORDER_HEADER

STATUS CHAR 4 Individual object status(short form)

DIALOG_ CHAR 1 One-character indicator

Page 26: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 25

POSSIBLE

OPERATION_ID NUMC 8 General counter for theorder

Note

The parameter OPERATION_ID specifies for which operation a date should be agreed.

Export Parameters

Parameter Name Component Data Type Length Short Text

ORDER_

NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

STREET CHAR 35 Street and house number

ORDER_HEADER_RETURN

STATUS CHAR 4 Individual object status(short form)

ERROR_CODE NUMC 4 Counter parameters

ERROR_

DESCRIPTION

CHAR 70 Character field of length 70

Tables

Parameter Name Component Data Type Length Short Text

ID NUMC 8 General counter for theorder

COUNTER CHAR 4 Operation number

OPERATIONS

SUB_

COUNTER

CHAR 4 Sub-operation

Page 27: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 26

UPDATE_

FLAG

CHAR 1 Update indicator

DESCRIPTION CHAR 40 Operation short text

EARLIEST_

START_DATE

DATS 8 Earliest scheduled start:Execute (date)

EARLIEST_

START_TIME

TIMS 6 Earliest scheduled start:Execute (time)

LATEST_

START_DATE

DATS 8 Latest scheduled start:Execute (date)

LATEST_

START_TIME

TIMS 6 Latest scheduled start:Execute (time)

EARLIEST_

FINISH_DATE

DATS 8 Earliest scheduled finish:Execute (date)

EARLIEST_

FINISH_TIME

TIMS 6 Earliest scheduled finish:Execute (time)

LATEST_

FINISH_DATE

DATS 8 Latest scheduled finish:Execute (date)

LATEST_

FINISH_TIME

TIMS 6 Latest scheduled finish:Execute (time)

NUMBER_OF_CAPACITY

NUMC 2 Two-figure number

WORKCENTER CHAR 8 Work center

PLANT CHAR 4 Plant

AMOUNT_OF_WORK

FLTP 16

SCHED_

PARAM1

CHAR 4 Scheduling parameters forexternal scheduling

SCHED_

PARAM2

CHAR 4 Scheduling parameters forexternal scheduling

SCHED_

PARAM3

CHAR 4 Scheduling parameters forexternal scheduling

OPERATION_ID NUMC 8 General counter for theorder

QUALIFICATION_ID

NUMC 8 Object ID

RATING NUMC 4 Characteristics of a qualityscale

REQUIREMENTS

ESSENTIAL CHAR 1 Indicator: Mandatory oroptional requirement

Page 28: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 27

EARLIEST_

START_DATE

DATS 8 Earliest scheduled start:Execute (date)

EARLIEST_

START_TIME

TIMS 6 Earliest scheduled start:Execute (time)

LATEST_START_DATE

DATS 8 Latest scheduled start:Execute (date)

LATEST_START_TIME

TIMS 6 Latest scheduled start:Execute (time)

EARLIEST_

FINISH_DATE

DATS 8 Earliest scheduled finish:Execute (date)

EARLIEST_

FINISH_TIME

TIMS 6 Earliest scheduled finish:Execute (time)

LATEST_

FINISH_DATE

DATS 8 Latest scheduled finish:Execute (date)

LATEST_

FINISH_TIME

TIMS 6 Latest scheduled finish:Execute (time)

PERS_

NUMBER

NUMC 8 Object ID

APPOINTMENTS

PERS_NAME CHAR 40 Text of length 40

Note

The components PERS_NUMBER and PERS_NAME are active, but are not transferred tothe interface in Release 4.6C.

After this function module has been called, possible dates must be transferred to the SAPSystem in the table APPOINTMENTS.

Page 29: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 28

Function ModulePM_ORDER_EXTERN_BOOK_DEFAULT

UseThis function module is a component of the CS-SDL interface [Extern] with which an externalscheduling system can be connected to the order processing function in the application areasPlant Maintenance and Customer Service.

IntegrationWhen you save the order, the systems calls up the interfacePM_ORDER_EXTERN_BOOK_DEFAULT in order to transfer the data to be posted to theexternal scheduling system. This ensures that if the external system is called exactly once,the call is a transactional remote function call [Extern]. In order to ensure that the correctsequence of the external system call is observed, the call occurs as a QUEUE-RFC. Thequeue name is composed of the fixed value CS_SDL and the order number.

PrerequisitesYou have assigned the function module PM_ORDER_EXTERN_BOOK_DEFAULT to thefixed value B in Customizing under Plant Maintenance and Customer Service → Maintenanceand Service Processing → Maintenance and Service Orders → Scheduling → ExternalScheduling → Configure Communication.

Features

Import Parameters

Parameter Name Component Data Type Length Short Text

ORDER_NUMBER

CHAR 12 Order number

OWN_

LOGICAL_

SYSTEM

CHAR 10 Logical system

START_DATE DATS 8 Order start date

START_TIME TIMS 6 Order start date (time)

END_DATE DATS 8 Order finish date

END_TIME TIMS 6 Order finish date (time)

PRIORITY CHAR 1 Order priority

PREFERRED_ENGINEER

NUMC 8 Object ID

ORDER_TYPE CHAR 4 Order type

CUSTOMER_NUMBER

CHAR 10 Customer number

POST_CODE CHAR 10 Postal code

CITY CHAR 35 City

ORDER_

HEADER

STREET CHAR 35 Street and house number

Page 30: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 29

STATUS CHAR 4 Individual object status(short form)

Tables

Parameter Name Component Data Type Length Short Text

ID NUMC 8 General counter for theorder

COUNTER CHAR 4 Operation number

SUB_COUNTER CHAR 4 Sub-operation

UPDATE_

FLAG

CHAR 1 Update indicator

DESCRIPTION CHAR 40 Operation short text

EARLIEST_

START_DATE

DATS 8 Earliest scheduled start:Execute (date)

EARLIEST_

START_TIME

TIMS 6 Earliest scheduled start:Execute (time)

LATEST_

START_DATE

DATS 8 Latest scheduled start:Execute (date)

LATEST_

START_TIME

TIMS 6 Latest scheduled start:Execute (time)

EARLIEST_

FINISH_DATE

DATS 8 Earliest scheduled finish:Execute (date)

EARLIEST_

FINISH_TIME

TIMS 6 Earliest scheduled finish:Execute (time)

LATEST_

FINISH_DATE

DATS 8 Latest scheduled finish:Execute (date)

LATEST_

FINISH_TIME

TIMS 6 Latest scheduled finish:Execute (time)

NUMBER_OF_CAPACITY

NUMC 2 Two-figure number

WORKCENTER CHAR 8 Work center

PLANT CHAR 4 Plant

AMOUNT_OF_WORK

FLTP 16

SCHED_

PARAM1

CHAR 4 Scheduling parameters forexternal scheduling

OPERATIONS

SCHED_

PARAM2

CHAR 4 Scheduling parameters forexternal scheduling

Page 31: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 30

SCHED_

PARAM3

CHAR 4 Scheduling parameters forexternal scheduling

OPERATION_ID NUMC 8 General counter for theorder

QUALIFICATION_ID

NUMC 8 Object ID

RATING NUMC 4 Characteristics of a qualityscale

REQUIREMENTS

ESSENTIALX CHAR 1 Indicator: Mandatory oroptional requirement

Page 32: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 31

Function Module READ_WORKLOAD

UseThis function module is a component of the CS-SDL interface [Extern] with which an externalscheduling system can be connected to the order processing function in the application areasPlant Maintenance and Customer Service.

IntegrationThe function module READ_WORKLOAD defines the interface with which the actual dates forthe technician are read from the external scheduling system when the graphical monitor[Extern] is started or refreshed.

PrerequisitesYou have assigned the function module READ_WORKLOAD to the fixed value R inCustomizing under Plant Maintenance and Customer Service → Maintenance and ServiceProcessing → Maintenance and Service Orders → Scheduling → External Scheduling →Configure Communication.

Features

Import Parameters

Parameter Name Component Data Type Length

Short Text

START_DATE DATS 8 Date and time, local date ofuser

END_DATE DATS 8 Date and time, local date ofuser

WORKCENTER_

ID

NUMC 8 Operating resources objectID

Tables

ParameterName

Component Data Type Length Short Text

OTYPE CHAR 2 Object IDPERSONS

PERNR NUMC 8 Personnelnumber

TYPE CHAR 1 One-characterindicator

REFID CHAR 40 Character,

40 figures

ID CHAR 70 Character field oflength 70

TEXT CHAR 80 Char 80

WORKLOAD

START_DATE DATS 8 Date and time,local date of user

Page 33: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 32

START_TIME TIMS 6 Date and time,local time of user

END_DATE DATS 8 Date and time,local date of user

END_TIME TIMS 6 Date and time,local time of user

Note

When this function module is called, the system transfers the work center ID that inquiresabout the current technician assignments to you using the parameter WORKCENTER_ID. Atthe same time, you receive a list of the current technicians for this work center in the tableMSM_PERSON. The components OTYPE has the fixed value P.

After the function module has been called, the list of technician assignments should beavailable in the table RIGHT_HAND. The component REFID must refer to a valid PERNRcomponent. You transfer the order number using the component ID. The component TYPEmust have the fixed value X.

Page 34: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 33

Function ModulePM_ORDER_EXTERN_MASTER_DATA

UseThis function module is a component of the CS-SDL interface with which an externalscheduling system can be connected to order processing in the application areas CustomerService (CS) and Plant Maintenance (PM).

It enables you to read the necessary master data from the SAP System using one of yourown programs. This function module must be called up from the external scheduling system.

Features

Import Parameters

Parameter Name Component Data Type Length

Short Text

PLANT CHAR 4 Plant

WORKCENTER CHAR 8 Work center

ENGINEER NUMC 8 Object ID

START_DATE DATS 8 Field of type DATS

END_DATE DATS 8 Field of type DATS

TIME_INFO CHAR 1 One-character indicator

QUALIFICATION_INFO

CHAR 1 One-character indicator

WORKCENTER_CATEGORY

CHAR 4 Work center category

Tables

Parameter Name Component Data Type Length

Short Text

PLANT CHAR 4 Plant

WORKCENTER CHAR 8 Work center

ENGINEER ID NUMC 8 Personnel number

ENGINEERNAME

CHAR 40 Object name

ENGINEERPOSTCODE

CHAR 10 Postal code

ENGINEER CITY CHAR 35 City

ENGINEER_

MASTERDATA_

ORG_UNIT

ENGINEERSTREET

CHAR 35 Street and house number

ENGINEER ID NUMC 8 Personnel numberENGINEER_

MASTERDATA_

QUALI

QUALIFICATIONID

NUMC 8 Object ID

Page 35: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 34

RATING NUMC 4 Characteristics of a qualityscale

PERNR NUMC 8 Personnel number

DATE DATS 8 Validity start date

BTIME TIMS 6 Start time

PLPWS CHAR 2 Time description of dailywork schedule

BREAK CHAR 1 Break indicator

TDATA CHAR 1 Origin indicator of the timerecord

MOABW NUMC 2 Grouping for subtypes

DETAIL CHAR 4 Subtype

AVAIL CHAR 1 Employee availability status

ENGINEER_

TIMELIST

HOURS DEC 8 Hours

For more information on interpreting the components in the table ENGINEER_TIMELIST, seethe documentation on BAPI_TIMEAVAILSCHEDULE_BUILD.

Page 36: CS-SDL Interface (CS-SE-SD) - SAP

SAP Online Help 01.03.00

CS-SDL Interface (CS-SE-SD) 46C 35

Scheduling an Order Externally

UseYou want to perform scheduling for the orders in your company using an external schedulingsystem.

PrerequisitesFor more information on the prerequisites, see External Scheduling [Seite 5].

The function module PM_ORDER_EXTERN_SCHED_DIALOG [Seite 17] must be assignedto the fixed value D in Customizing under Plant Maintenance and Customer Service →Maintenance and Service Processing → Maintenance and Service Orders → Scheduling →External Scheduling → Configure Communication.

Procedure1. Depending on which application component you are working in, choose

• Logistics → Plant Maintenance → Maintenance Processing → Order → Create (General)

• Logistics → Customer Service → Service Processing → Order → Service Order →Create (General)

2. Create an order.

3. Choose Schedule.

4. The Schedule agreement dialog box appears.

5. Enter the following data:

• Date type

• Customer calendar

• Scheduling rule

6. Select the pushbutton Proposed Dates.

7. The external scheduling system looks for suitable dates and returns the proposed datesto the SAP System.

8. Select a suitable date and confirm.

9. The order header screen is displayed.

10. You can either change or complete the order.

11. Save the order.

ResultThe dates are posted in the SAP System and in the external scheduling system.

If the external scheduling system does not find any suitable dates, you can change the basicdata of the order and reschedule it.