SAP Function BAPI_IE4N_EXCHANGE - Exchange of Two Pieces of Equipment

Parameter Reference Type Length Default Optional Text
IS_DATA_NOTIFICATION1 BAPI_IE4N_NOTIFICATION u 29 Notification Data for Equipment Installation/Dismantling with Goods Movement
IS_DATA_NOTIFICATION2 BAPI_IE4N_NOTIFICATION u 29 Notification Data for Equipment Installation/Dismantling with Goods Movement
I_EQUIPMENT1 BAPI_ITOB_PARMS-EQUIPMENT C 18 X Equipment Number
I_EQUIPMENT2 BAPI_ITOB_PARMS-EQUIPMENT C 18 X Equipment Number
I_EXCHANGE_DATE BAPI_ITOB_EQ_INSTALL_EXT-INST_DATE D 8 Date on which installation location of equipment was changed
I_EXCHANGE_TIME BAPI_ITOB_EQ_INSTALL_EXT-INST_TIME T 6 Time at which the InstallLoc of the equipment was changed
I_FORCED_EXCHANGE BAPIFLAG-BAPIFLAG C 1 SPACE X Forced Exchange
I_MATERIAL1 BAPI_ITOB_EQ_ONLY-MATERIAL C 18 X Material Number
I_MATERIAL1_EVG BAPIMGVMATNR u 82 X BAPI Structure for Transfer of External Material No, Ver.,
I_MATERIAL2 BAPI_ITOB_EQ_ONLY-MATERIAL C 18 X Material Number
I_MATERIAL2_EVG BAPIMGVMATNR u 82 X BAPI Structure for Transfer of External Material No, Ver.,
I_NO_MPL_LOCAL_CHECK BAPIFLAG-BAPIFLAG C 1 X MPL Flag: ' ' - Execute MPL Check; 'X' - No Check
I_SERIALNUMBER1 BAPI_ITOB_EQ_ONLY-SERIALNO C 18 X Serial Number
I_SERIALNUMBER2 BAPI_ITOB_EQ_ONLY-SERIALNO C 18 X Serial Number
I_SIMULATION BAPIFLAG-BAPIFLAG C 1 X Checkbox

Parameter Reference Length Optional Text
EXTENSION_IN BAPIPAREX 990 X Reference Structure for BAPI Parameters EXTENSIONIN/EXTENSIONOUT
IT_LONGTEXT1 BAPI2080_NOTFULLTXTI 152 X Notification Long Text
IT_LONGTEXT2 BAPI2080_NOTFULLTXTI 152 X Notification Long Text
RETURN BAPIRET2 548 Return Parameter(s)

Functionality
This BAPI provides the swap function to transaction IE4N without aninterface being processed.
Two items of equipment can swap their installation location using thisfunction module. The equipment items must be serial numbers
A maintenance notification is created that documents each dismantling orinstallation. Four maintenance notifications are created in total.

Notes
An update is triggered within the function module, that is, eachequipment installation is updated immediately. An update is not tri
ggered in simulation mode (import parameter I_SIMULATION).
In tables IT_LONGTEXT1 and IT_LONGTEXT2, long texts can be defined forthe maintenance notifications being created. Only one long text issupported for the notification header, therefore the OBJTYPE field mustcontain the value QMEL. The OBJKEY field must be initial.
Customer-specific fields can be transferred to the module using theimport table EXTENSION_IN. The fields must then be entered in therelevant structures using the MODIFY_DATA method in the BAdIBAPI_IE4N_EXTEND. Other customer enhancements and checks can also beimplemented in this method. Note that no dialogs are processed in themethod, however.
All messages that accumulate during processing are returned in tableRETURN. If there are errors, the table also contains the relevant errormessages.

Further information
For more information, see the documentation for transaction IE4N.

Description
The data required to create a notification for the first of theequipment items being swapped is transferred in this structure.
When two items of equipment are swapped, an installation notificationand a dismantling notification are created for each item. This meansthat four notifications are created in total.
The entry of notification numbers is not supported when equipment isswapped. Only the DISM_PLANNED and DISM_UNPLANNED fields are used. Theother fields in the structure are not taken into account.
You use table IT_LONGTEXT1 to create long texts for the messages.

Default
None

Description
The data required to create a notification for the second equipment itembeing swapped is transferred in this structure.
When two items of equipment are swapped, an installation notificationand a dismantling notification are created for each item. This meansthat four notifications are created in total.
The entry of notification numbers is not supported when equipment isswapped. Only the DISM_PLANNED and DISM_UNPLANNED are used. The otherfields in the structure are not taken into account
Use table IT_LONGTEXT2 to create long texts for the messages.

Default
None

Description
Number that uniquely identifies the first item of equipment to beswapped.
The equipment must be a serial number. Alternatively, the materialnumber and the serial number can be specified.

Default
None

Description
Number that uniquely identifies the second item of equipment to beswapped.
The equipment must be a serial number. Alternatively, the materialnumber and the serial number can be specified.

Default
None

Description
Date on which the two items of equipment are due to be swapped.

Value range
The date cannot be a future date.

Default
None

Description
Time at which the two items of equipment are due to be swapped.

Default
None

Description
If this indicator is set, the two items of equipment are swapped despitea CCM validation error.

Value range
'X' and SPACE

Default
Not set

Description
Material number of the first item of equipment to be swapped. Thecombination of material number and serial number uniquely identifies theequipment.
Alternatively, the equipment number can be entered directly.

Default
None

Description
Parameter for long material number
You can use this parameter to transfer long material numbers, with amaximum length of 40 characters.
Before you can use this parameter, you must switch on the switch forbusiness function LAMA (long material number) in the system.
Business function LAMA is available as part of the business function setfor DIMP.

Value range
None

Default
None

Description
Material number of the second item of equipment to be swapped. Thecombination of material number and serial number uniquely identifies theequipment.
Alternatively, the equipment number can be entered directly.

Default
None

Description
Parameter for long material number
You can use this parameter to transfer long material numbers, with amaximum length of 40 characters.
Before you can use this parameter, you must switch on the switch forbusiness function LAMA (long material number) in the system.
Business function LAMA is available as part of the business function setfor DIMP.

Value range
None

Default
None

Description
You can use this parameter to deactivate the checking of the plannedstructure (master part list).

Value range
'X' and SPACE

Default
Not set

Description
Serial number of the first item of equipment to be swapped. Thecombination of serial number and material number uniquely identifies theequipment.
Alternatively, the equipment number can be entered directly.

Default
None

Description
Serial number of the second item of equipment to be swapped. Thecombination of serial number and material number uniquely identifies theequipment.
Alternatively, the equipment number can be entered directly.

Default
None

Description
If this indicator is set, the swapping of the equipment is simulated. Noactual changes are made.

Value range
'X' and SPACE

Default
Not set

Description
Additional fields can be transferred to the BAPI using this table.
These fields can be processed using the BAdI methodBAPI_IE4N_EXTEND->MODIFY_DATA.

Default
Empty

Description
The table displays the lines of the notification long text for thenotifications of the first item of equipment being swapped.
Long texts are currently only created for the notification header, thatis, the OBJTYPE field must contain the value 'QMEL', and the OBJKEYfield must be initial.

Default
Empty

Description
The table displays the lines of the notification long text for thenotifications of the second item of equipment being swapped.
Long texts are currently only created for the notification header, thatis, the OBJTYPE field must contain the value 'QMEL', and the OBJKEYfield must be initial.

Default
Empty

Description
Return table based on BAPI standard containing all messages generatedduring processing. If there are category E or A messages, this meansthat the data has not been saved.