cancel
Showing results for 
Search instead for 
Did you mean: 

Set Expected event date based on planned dates

petra_just
Active Participant
0 Kudos

hi exerts,

Our expected events are generated, but do not have a planned date/time. In the expected event profile, I have seen a possibility to add a function that sets the expected date. We need to set the expected event date/time for loading and unloading events. We would like to read it from the related stage. We would like to use the requested start date/time or better the Planned loading date/time (for load_end) and the Planned unload date/time for UNLOAD_END.

I have created a new new multi-task activity and assigned the standard UPDATE_EE_DATETIME to it. Then, I have assigned the Z-mutli-taks activity to the exp event profile. But, when I cancel the FU, the debugger does not stop in method ACT_UPDATE_EE_DATETIME. Could you give me a hint what my error is?

Also, I have seen expected event date/time being set in previous versions without any enhancement. Is this a new functionality with 9.4? Is there a standard way to set the expected event date/time. If not, what would be the smartest way to set the expected date/time?

My idea would be to get to the doc id from the EH_GUID using table /SAPTRX/EH_HDR

and read the related stop. To link the correct stop, I would read the outbound stop for the load_end event with the same location and the inbound stop for the unload_end event. Has someone done this before. What would be your hints?

Thanks so much. I appreciate the support received.

Petra

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Petra,

There are different options you can set expected event dates based on related events.

1. Go to Expected Event Profile -> Select your expected event profile -> Expected Event date block -> make date rule as "Relative to Unique Event", Set Duration (00:00 or 24:00), Select Add duration, Enter Group Number (always same group number), Item number (this is important which the related event number you want to relate), Select Calculation rule Expected event date or message received date to set Expected event date.  This configuration help you to set the expected event when the event handler is created.  Ref OCB10_CONTAINER Expected Event Profile for configuration.

If you have custom expected event to set, then create a new functional module and assign it to Set EE Date Fct

2. EVM_EE_UPDATE Activity: This activity help you to set expected event date and time in loading and unloading event when you send event message of previous event.

Could you please tell me why do you want to configure in expected event monitor instead of above options?

Regards


GGOPII

petra_just
Active Participant
0 Kudos

hi Ggopii,

have tried to set the ee dates in standard as follows:

but, still the dates are empty. We have upgraded to version 9.3.

Before the upgrade, the dates were filled. It looks like it may be an upgrade problem. see:

Thank you very much for your input  and I would be interested to see how and where I can set up a custom function for expected event setting, where I can find ODT40_TO_EXP_EV_DATE. In parallel, I will open an oss incident because it looks liek an upgrade problem.

Regards

Petra

former_member186607
Active Contributor
0 Kudos

Hi Petra,

your requirements to set the expected dates of the expected events should definitely be handled in the expected event extractor in SAP TM (coding). There you have all the planning dates available.

With TM 9.3 the data model of TM has been changed in some parts which have impact on the extraction of the expected events.

The standard extractors have, of course, been adapted to the new data model, but if you have custom extractors assigned, you will probably have to do some changes here, because now different fields are used in the TM data model, e.g. for planned loading/unloading times.

We have created a little guide for this. So please check this document on what you have to condsider regarding your extraction function modules when upgrading to TM 9.3:

Best regards, Daniel

Former Member
0 Kudos

Hi Petra,

It may be a bug in the program after the upgrade or custom program couldn't meet with newly updated programs.  First, check with your developers on custom program to check. If you still find an issue then you can create OSS message and give the number here to Daniel and Steffen, he will help you to resolve ASAP.

Regards


GGOPII

sukumar_perumalsamy
Participant
0 Kudos

Hello Petra,

Seems like issue with EE extractor function in TM , as it's failed to update the EE date time to EM  system or EE date time is not "Read from" EM to TM in NWBC layer .

Cheers,

Sukumar

petra_just
Active Participant
0 Kudos

hi Daniel,

thx for your answer. But, I cannot access the document link. Please let me know if the standard should still set the expected event dates as usual after the upgrade or if there is already a note for this. Shall I open an oss note for this?

Thanks

Regards

Petra

former_member186607
Active Contributor
0 Kudos

Hi Petra,

the document should be available and the link should work - I just double-checked. Can you please retry?

The standard expected event extractors should still work - they have been adapted. So if you are really using the standard expected event extractor - then please open an OSS message.

If you are using custom extractor, then please first check on what needs to be changed after upgrading.

Best regards, Daniel

petra_just
Active Participant
0 Kudos

Hi Daniel,

have sent a pre-formulated oss incident to my customer who will open the note. But, I can still not access the document. When clicking the link, it authentifies my sap user correctly and sends an error message. Would you kindly send it to my e-mail p-hunger@email.de?

Thanks so much for your support. It is highly appreciated.

Petra

former_member186607
Active Contributor
0 Kudos

Hi Petra,

I have sent the SCN guide to your e-mail. Have you already checked the general TM consulting note 2171821 regarding the upgrade to TM 9.3?

The refactoring guide which is attached to this note should definitely be checked in detail!

Best regards, Daniel

petra_just
Active Participant
0 Kudos

ok, yes, it worked with Chrome . thx

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Petra,

By standard, Loading and Unloading start/end dates come from either TU stops or FO Stops. This logic resides in Application ( TM in this case ) side EM extractors( Expected Events extractor from AO Types ).

If by standard expected dates are not being populated then:

1) I would look into expected events extractor and see why the milestone dates are not being populated ( debug will help ). Contact SAP if required.

2) See if BADI /SCMTMS/SEND_TOR_DATA helps you with the required TOR data to rebuild the expected events. I haven't personally done it but looks promising.

3) Other option ( which I prefer for my projects) to customize the AO Type and add the custom extractor. Which also means creating custom EH Type ( copying the standard should help with some adjustments to other profiles)

I would not recommend building the milestone dates in EM ( EE Monitor, EE Profile functions, Ruleset etc ) as:

1) It's unnecessary overhead on the EM

2) Responsibility of building the expected dates should be on the Application systems since you said these dates are available on the related stops.

3) Building expected dates via EE Monitor/EE Profile functions/Ruleset should be used in extreme conditions like dates not being available on Application system and dates being available only during runtime like posting events or non-application system scenarios.

4) You should try to stay away from calling Application system from EM as much as possible, again due to performance. Think of TM and EM as different applications on different boxes even though you might have them in the same box;)

To your question, why ACT_UPDATE_EE_DATETIME is not getting triggered when you cancel FU is that EE monitor will not get triggered if you cancel any document. It will trigger when you run the EE Monitor. If at all, you need to add your custom EE function to your individual expected events as in picture:

Thanks,

Vishnu

Former Member
0 Kudos

Hi Petra,

Sorry. I didn't see Daniel's response and your subsequent threads ended up writing my own response.

Thanks,

Vishnu

petra_just
Active Participant
0 Kudos

Vishnu,

no problem. Thanks for helping me on this one and your information is also useful.

thx

Petra

sukumar_perumalsamy
Participant
0 Kudos

Hi Petra,

Application system expected event extractor has the standard  logic  to set the expected event date and time .

Check the expected event extractor logic in TM system(/SCMTMS/EXTR_EE_TO - Freight order , /SCMTMS/EXTR_EE_FU for freight unit ) , you can add custom logic as enhancement option in the standard extractor based on the business requirements.

In EM you can change/update the expected event date/time based on the reported event  directly in EM and you have to enable the custom activity to update the subsequent event EE date/time & send the updated date and time to TM/ECC  system.

Cheers,

Sukumar