1 Reply Latest reply: May 2, 2013 3:23 PM by Alan Farrell RSS

    Date Format

    Alec Harf

      Hi guys,

       

      I have loaded a date field coming from Sharepoint list and the format in it  MMM DD YYYY

       

      I am trying to change the format so I did Date(Fieldname,''M/D/YYYY') as Date1

       

      But the result wasn't as expected. the field is not ahowing any data in it.

       

      I am not sure if that's because QV is not recognizing the field as date?!

       

      Please let me know your thoughts.

       

      Best,

      Alec

        • Re: Date Format
          Alan Farrell

          You need to put the Input Format and then the Output format

           

          Like below

           

          DATE( DATE#( FieldName, 'MMM D YYYY'), 'YYYY-MM-DD') as Date1

           

          That should do it

           

          DATE# converts the Input Date to a serial number and the Output format ensures it reads the serial number and converts that to the correct date format

           

          Regards

           

          Alan