SAP Knowledge Base Article - Public

2911501 - Error While Execution of Custom Mass Data Run

Symptom

You may receive an error "Daylight Saving Time Indicator of parameter DATETIME is not valid" while executing an MDRO in the results section of application log.

Environment

SAP Cloud Application Studio

SAP Business ByDesign

SAP Cloud for Customer

Reproducing the Issue

  1. Go to Work Center XXXX. ( XXXX stands for Custom Work Center name).
  2. Navigate to the view YYYY.( YYYY stands for Custom Work Center view).
  3. Select the Run ID.
  4. Choose Schedule to execute the Mass Data Run as Immidiately.
  5. Open the application log.
  6. Check the Result section for details
  7. You will see an error "Daylight Saving Time Indicator of parameter DATETIME is not valid"

Cause

The error is occurring while trying to execute  custom logic as you have not set the value of daylightSavingTimeIndicator for this.OldLastRunDate and is calling 'this.OldLastRunDate.ConvertToGlobalDateTime() with daylightSavingTimeIndicator not correctly set for the corresponding input value.

Note - Reuse library function LocalDateTime.ConvertToGlobalDateTime does not automatically set daylightSavingTimeIndicator.This is the expected behavior.

You  can raise a new requirement request for automatic calculation of daylightSavingTimeIndicator in LocalDateTime.ConvertToGlobalDateTime or a similar API for the same, via the Influence Portal (links are mentioned below for Influence Portal ).

SAP Business ByDesign at https://influence.sap.com/sap/ino/#/campaign/886

SAP Cloud For Customer at https://influence.sap.com/sap/ino/#/campaign/903

Based on voting and feedback our product development team will condiser this in on of the future releases.

Resolution

As a work around, you have to first use LocalDateTime.ParseFromString and then call ConvertToGlobalDateTime()

You  can prepare a string from the input value in this.OldLastRunDate(for eg: string as "20191015120000 CET").

This string can be passed as input to LocalDateTime.ParseFromString. Further,the output from LocalDateTime.ParseFromString can be passed as input to LocalDateTime.ConvertToGlobalDateTime.

******************************************************************************

 Sample code snippet(just for an example)

 var string_123 = this.LastRunDate.content.ToString() + " " + this.LastRunDate.timeZoneCode ;

 var mno = LocalDateTime.ParseFromString(string_123);

 mno.ConvertToGlobalDateTime();

*******************************************************************************

Note: The above mentioned example is just for the purpose of explanation to  you . Please try out a similar logic,test it thoroughly before releasing the code and using it productively.

See Also

Please refer to SAP Help documentation and refer to example given there for LocalDateTime.ConvertToGlobalDateTime for more details.

https://help.sap.com/docs/SAP_CLOUD_APPLICATIONS_STUDIO/cbcebe3cfb1647a8b0322c18dbb0b481/7522d80b73e2101481858d76f4bd912e.html?locale=en-US&q=LocalDateTime.ConvertToGlobalDateTim

Keywords

MRD run hangs;Daylight Saving Time Indicator of parameter DATETIME is not valid;MDR failed. , KBA , day light saving indicator , mdr fails , AP-RC-BDS-MDR , ByDesign Studio Mass Data Run , Problem

Product

SAP Business ByDesign all versions ; SAP Cloud for Customer add-ins all versions ; SAP Cloud for Customer core applications all versions