Skip to main content
12-Amethyst
February 6, 2024
Question

How to ensure a DateTime or Timestamp type is returned

  • February 6, 2024
  • 2 replies
  • 897 views

Hi, 

I am using the Decode Datebase Function to return a datetime when a task has a status of "Completed". 
It looks like this:

mariaSutton_0-1707250651543.png

 

However, when I use the above approach the return type is string and not a timestamp.

The reason I want a timestamp for this value is so the user can set the criteria/param before generating the report easily by selecting a date from the calendar picker (like in the image below) instead of entering free text. 

mariaSutton_1-1707251304879.png

 

 

2 replies

HelesicPetr
22-Sapphire II
22-Sapphire II
February 7, 2024

Hi @mariaSutton 

If you use Datebase Function the return value is always string,

You would need to retype the output as you has asked, but I am not sure you can do that in the Reporting Management (QueryBuilder).

PetrH

joe_morton
18-Opal
18-Opal
April 9, 2024

Why do you need to use the database function? Can't you get the timestamp directly from a "Reportable Item"?