on 04-14-2010 5:01 PM
We would like to pull out of our Event Handler an ID (whether query or tracking) can we accomplish this using the BAPI /SAPTRX/BAPI_EH_ADDEVENTMSG_02 ??
IF so what are the fields that are required? We can successfully deactivated an EH but we don't want that we just want to pull it out of the EH set.
For example when a delivery is deleted from a shipment we don't want to track that shipment in our EH set anymore (our set being sales order, delivery, shipment).
We had made some changes that actually didn't delete the EH even if it was deleted in the AO system. We now have decided to use an alternative method of updating a different EH when a deleting of an AO occurs. I will outline this in the thread
The whole problem comes that we need to capture a metric in BI of a sales order line that is "Ready To Ship". So if a delivery is deleted or a delivery is removed from a shipment (deleted) then this needs to update the sales order line to let it know that this occured. I was hoping just to show that the EH was deactivated in a EH set. However, I now know that the EH is deleted completely when the AO is deleted. This is where the thread above comes into play allowing us to look at all event types even though the EH was deleted
I hope this helps some of you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Alex,
I am not sure why you would need to do this. If your EH set groups based on a shipment number and the delivery is deleted it is also deactivated (The delivery EH) and deleted from the shipment doc which means it wouldn't be picked up by the EH set anymore. If you are grouping on Sales Order number then again when the delivery is deleted the corresponding EH for the delivery is deleted and will no longer appear in the EH Set.
Can you provide more details on your scenario?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
As a side note though you can manipulate the Tracking IDs using the trackreferences table in the Add event bapi.
The code below shows how to add a delivery number as the tracking ID. Change the action to D to deactivate the Tracking ID.
* Add reference number for DEL_NO tracking ID
ls_trackreferences-evtcnt = gv_evtcnt.
ls_trackreferences-refcod = 'DEL_NO'.
ls_trackreferences-refid = <ls_xlips>-vbeln.
ls_trackreferences-refusage = 'T'. <=== Tracking ID (Put Q for Query ID)
ls_trackreferences-action = 'A'. <=== Activate (Put D = Deactivate)
APPEND ls_trackreferences TO ct_trackreferences.
Hi -- Reviving an old post.. but I have the exact same question as the original poster, but my focus is specifically on the Query IDs. So, in our case, we need to be able to remove/delete a Query ID record. Not finding anything that gives us this ability.
I'm following the steps recommended by Kevin Wilson to populate the ls_trackreferences table, however I'm not finding a way to to process the event message from the rule set in EM. It was pointed out to use "TRACKING_ID_REMOVE", but this doesn't seem to process Query ID updates, only Tracking IDs.
Any advice would be great!
Thanks!
Hello Chris,
for Query IDs there is no activity available at the moment.
But you should be able to write an own activity doing it similar like the Tracking ID activity. The query ID structure /SAPTRX/EH_QRYID_DYN has also a field for an update Indicator.
I assume it will only work writing an activity method by an enhancement doing this:
(1) start Class Builder (SE24) for class /SAPTRX/CL_EH_EVENT_MSG_MODEL
in display mode
(2) The "Methods" tab appears
(3) Select menu function "Class >Enhance"
(4) The "Create Enhancement Implementation" popup appears;
create an enhancement implementation here
(5) after creating it you come back to the "Methods" tab, but now you
are in mode "Enhance class "
(6) scroll down to the end of the methods list; here you can add a
new method now ...
That new method will be automatically connected to
your enhancement impelmentation (you can see that in column
"Enhancement implementation")
Best regards,
Steffen
User | Count |
---|---|
9 | |
4 | |
3 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.