2 Replies Latest reply: Jul 30, 2013 11:00 AM by Aji Paul RSS

    Simple inline load question

      Hi All,

      I am trying to load an inline table with datetime.

       

      My data in in 'DD/MM/YYYY hh:mm:ss' format.

       

      Here is the script I originally used

       

       

      [DTAB]:

      load * inline

      [DT1,DT2

      1/2/2013 11:45:12, 3/16/2013  12:12:12

      7/10/2013 10:40:05,7/16/2013  05:10:01];

       

       

      but this resulted in a text load.

       

      So I tried with the explicit date format and the it came out as null

       

      load * ,

        date(date#(DT1,'DD.MM.YYYY hh:mm:ss'),'DD.MM.YYYY hh:mm:ss') as I_DT1,

      date(date#(DT1,'DD.MM.YYYY hh:mm:ss'),'DD.MM.YYYY hh:mm:ss') as I_DT2,

      date(DT1,'DD.MM.YYYY hh:mm:ss') as II_DT1,

      date(DT1,'DD.MM.YYYY hh:mm:ss') as II_DT2

      inline

      [DT1,DT2

      1/2/2013 11:45:12, 3/16/2013  12:12:12

      7/10/2013 10:40:05,7/16/2013  05:10:01];

       

      Anyone would please be able to provide some details on this?

       

      Thanks,

      AP