Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

Day of function in Report Definition returns wrong day

SA-31245

Summary



Using the 'Day of' function on pyResolvedTimestamp returns wrong day in Report Definition


Error Messages



Not Applicable


Steps to Reproduce

  1. Create a Report Definition to report on resolved work items.
  2. In the Report Definition configure a column as Day of(.pyResolvedTimestamp).
  3. Resolve a work item such that its timestamp would fall in today as per server's local time and when converted to GMT it would fall in next day.
  4. Run the report and see that Day of(.pyResolvedTimestamp) returns next day while the item was resolved today.


Root Cause



Pega 7 stores the timestamp in GMT time in the blob. When a column is exposed the timestamp is stored in the local time of the server. If the data is read via an Obj-browse or Obj-open, the Engine does the proper conversion from GMT to local time. However in the ‘Day of’ function alias used in a Report Definition, it uses the timestamp stored in the local time of the server and may return an unexpected result.

Resolution



Perform the following local-change:

Create a function alias using the pxDay function alias and handle the conversion.

 

Published December 14, 2016 - Updated October 8, 2020

Was this useful?

100% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice
Contact us