Skip to main content
New Participant
Nov 10, 2021 5:38 AM UTC
Question

I am facing issue like while I am trying retrieve the data from the data base I am getting Z as default for date , I only need date as MM/DD/YYYY format only. How can I fix this using expression role?

I am getting like 2000-02-12Z

I need 02-12-2000

    5 replies

    richardm900458
    Inspiring
    Nov 10, 2021 6:29 AM UTC

    Hi himabindu,
    try the text() function.

    example: 

    • text(today(),  "mm/dd/yyyy")

    docs.appian.com/.../fnc_text_text.html

    New Participant
    Nov 10, 2021 12:57 PM UTC

    Thanks for your reply, it works.

    stewart.burchell
    Employee
    Nov 10, 2021 8:54 AM UTC

    It's worth noting what the 'Z' actually represents: 

    The ISO 8601 standard defines formats for representing date-time values as text. The T is just a marker for where the time part begins. The Z is an abbreviation of +00:00 , meaning UTC (an offset of zero hour-minutes-seconds).

    This may be more pertinent for datetimes where the time being returned from your database might not be the local time you think it should be.

    richardm900458
    Inspiring
    Nov 10, 2021 8:55 AM UTC

    valuable comment :)