cancel
Showing results for 
Search instead for 
Did you mean: 

How to get GUIDs after posting event parameters

0 Kudos

Hello All,

I am getting my data from a flat file with serial number, event id and other fields using FM' /SAPTRX/BAPI_EH_ADDEVENTMSG_02' with this I am also updating a Z table with parameters along with guids, but after executing this bapi the return parameters does not return with guids for the events.

Now I have to update another Z table using the same internal table along with GUIDs, could any one let me know how to get the GUIDs for the events I posted.

Thanks,

Kishore.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hello Kishore,

If the parameters are the part of system/info/control then it will be always good to add rule set to udpate Z table and get EVM_GUID from I_EAI table.

Create Acitivity function and update Z table enteries in this function. Remember not to mentioned commit statement as it will impact your current ruleset processing.

Thanks,

Kinjal Rathod

0 Kudos

Hi Kinjal,

Thanks for the reply, but we could not update the z table using the function, as we need to get the guids and do some additional coding in the program. we need to get them back in the function module itself.

Thanks,

Kishore.

Former Member
0 Kudos

Hello Kishore,

Thanks for clarifying it. You can get TRXCOD and TRXID  from TRACKINGHEADER internal table which you would have filled at the time of calling /SAPTRX/BAPI_EH_ADDEVENTMSG_02 and go to table /SAPTRX/EVM_HDR search based on TRXCOD and TRXID.

Make sure to check against /SAPTRX/EH_EVMSG whether EVM_GUID is linked to event handler or not as there may be possible that your EH is locked and EVM_GUID is not linked to your event handler.

Hope this will help.

Thanks,

Kinjal Rathod

former_member190756
Active Contributor
0 Kudos

You could use a preprocessing function.

There you could get the current guids of the Event Messages. And store them e.g. in global table of a function group to have it later.

SPRO:

Event Management

      Event Messages, Status Queries, and Web Interface

          Define Criteria for Event Message Processing

Best regards,

Steffen

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Kishore,

You have to give Tracking ID header data to retrieve GUID.  First set the breakpoint in two areas

PERFORM data_preprocessing_02 and PERFORM fill_tables_02.  Now, Import parameters SIMULATE = X and enter data in table TRACKINGHEADER-EVTCOD then press F8.

You can see GUID's populated in APPEND lv_guid TO et_guids.

If you don't give Tracking Header Data then BAPI won't return the GUID's for the message.  Can you give me what is the return message you are getting like "Event message header table is empty".

Regards

GGOPII

0 Kudos

Thanks Gopi for  quick reply,

I am passing the header data and i can see guids created inside the FM, but the return table is only has one entry with success and no other table is returning with GUIDs, we need to get those GUIDs back from the FM so that we need some additional code needs to be done with those.

Thanks,

Kishore

Former Member
0 Kudos

Hi Kishore,

Can you give me your sample file (dummy data) to check what all fields you are passing into BAPI?  I can quickly check for you.

Also, can you elaborately explain "no other table is returning with GUIDs.

Regards

GGOPII