When using a date function on a script with predefined fields with dummy
values, the output format will be generated in numbers even when using Date().For example:
The below script contains predefined fields with Null() values (which we consider it as dummy). The Date field will be displayed in a number format even with correct function 'Date()' usage.
In Line 24 : The field Date1 is predefined with Null() on first table load.
In Line 29: The Date() used to override the custom format on second table load.Output Format:
Declaring NULL() value to Date field will overwrite custom format.
Working as designed as per QV-15780.
Workaround: Define dummy value such as Date(0) instead of NULL() (or) Do not declare dummy values to Date1 field as mentioned below:
NULL() as ID,
Date(0) as Date1