on 04-12-2013 9:24 AM
Hi All,
In SAP system, a configuration was done because of which the 'Reported by' field in Notification got mandatory. Now, while I am trying to create a Work Order in IW31, a information message pops up saying Field 'Reported by' must be filled. Refer below screenshot:
After receiving the message I went to Notification then and there to provide 'Reported by' field. Refer below screenshot:
After providing Reported by field, I went back to IW31 screen and was able to save and create the Work Order. Now I have to achieve the above functionality through ABAP. I checked BAPI_ALM_ORDER_MAINTAIN but could not find a solution.
Please help on how to populate Reported by field programmatically.
Thanks
Manish Verma
BAPI_ALM_ORDER_MAINTAIN is for creating orders only, it does not create notifications..
Here are some options:
PeteA
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pete,
I went ahead with your first option i.e. I created the Notification first, and then through IW21 screen I navigated to IW31 screen and created the Work Order. It fulfills my need.
Now I want to achieve it through BAPI. Please let me know what all BAPIs will be required and in which sequence it will be executed.
Thanks
Manish Verma
Hi All,
I have solved it myself. Following is the solution:
First we will create Notification using following BAPIs in sequence:
a) BAPI_ALM_NOTIF_CREATE
b) BAPI_ALM_NOTIF_SAVE
c) BAPI_TRANSACTION_COMMIT
After fetching the Notification number from above execution, we will now have to link the new order to the existing Notification number. Refer following code to accomplish the task:
IT_METHODS:
REFNUM OBJECTTYPE METHOD OBJECTKEY
000001 HEADER CREATETONOTIF %00000000001000010000105
000001 OPERATION CREATE %00000000001
000001 SAVE %00000000001
IT_HEADER-ORDERID = %00000000001
IT_HEADER-ORDER_TYPE = PM01
IT_HEADER-PLANPLANT = 1000
IT_HEADER-MN_WK_CTR = ASSEMBLY
IT_HEADER-NOTIF_NO = 000010000105
IT_OPERATION
Please note in the OBJECTKEY, notification number to be provided should be of 12 characters.
Regards
Manish Verma
From where, you will pass the data for Reported By field??
You have automated Notification creation while creating PM Order, I think.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
6 | |
5 | |
5 | |
5 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.