Need help for conversion of datetime (2019-04-10 04:00:00.0) to 10-APR-19
I have pxcreateDateTime being saved as DD-MMM-YY format. So I cannot pass the exact Pega current date when I am supposed to compare and retrieve 120 days older cases from current date.
I tried FormatDateTime and it did not work. If there is any Pega OOTB function available request you to please share it here,
Even the pxcreatedatetime is of different format in the data base, during run time Pega takes the base class property reference of pxcreateDatetime (DataTime) and that is the reason it is giving you the error of different types
Any specific reason for using only report definition?
You can try using the RDB-List which would also helps you in the performance and easy to query it.
Select Cast('27-Jun-18' as date) where Cast('27-Jun-18' as date)< DATEADD(dd, -120, DATEDIFF(dd, 0, GETDATE()));
Query for you would be in the RBD-List would be
Select * from Table_Name where cast(Column_name as date) < DATEADD(dd, -120, DATEDIFF(dd, 0, GETDATE()));
Keep up to date on this post and subscribe to comments