M.App Enterprise Discussions

Discuss topics with other M.App Enterprise Product pioneers and experts to get the most out of it.
Showing results for 
Search instead for 
Do you mean 
Reply
Highlighted
Frequent Contributor
Posts: 159
Registered: ‎01-14-2018
Accepted Solution

Another Date Format in M.App Enterprise workflow

Dear all,

 

Is there a way to change the default date format in a workflow,

for example I have a list that shows a field of type date; I want to show it in a format like 'dd-MM-YYY' as '4-october-2018'.

 

Kind Regards

Khaled

Frequent Contributor
Posts: 78
Registered: ‎10-12-2015

Re: Another Date Format in M.App Enterprise workflow

[ Edited ]

Hello,

 

One way to do this would be using a sqlselect on the field like (for postgres like below, sql server and oracle have different data formatting implementations):

sqlselect="SQL[to_char(DATE_START_12001,'dd-month-YYYY')]"

You might need to set the field to type="textfield", datatype="string" for it to be displayed correctly.

 

If you need the field to have a datepicker for saving/editing the value, you could have one formfield visible="form", type="datetimepicker", datatype="datetime", and one non-persisted formfield visible="list" that has the sqlselect=".." statement, using type="textfield", datatype="string".

 

Hope this helps.

Radu

Visitor
Posts: 1
Registered: ‎10-02-2018

Re: Another Date Format in M.App Enterprise workflow

[ Edited ]

Hi,

 

I manage to display date in format as given. But is there any way that I can sort the order of the date?

 

I've tried using this sqlselect as

 

sqlselect="SQL[ORDER BY to_char(DATE_START_12001,'dd-month-YYYY') DESC]"

 

but it gives error. Guide me.

 

Thanks