Hello Charles, It seems to work when I use one additional ' for escaping, for example try using 'yyyy-MM-dd''T''HH:mm:ss' for format.
Thanks, Igor On Thu, Feb 6, 2020 at 11:43 PM Ted Dunning <[email protected]> wrote: > That is really frustrating because that timestamp is literally in an ISO > 8601 format. > > https://en.wikipedia.org/wiki/ISO_8601 > > It would be nice if these formats just worked by default. > > > > > On Thu, Feb 6, 2020 at 5:05 AM Charles Givre <[email protected]> wrote: > > > Hi Drill Devs > > I'm having a small issue interpreting timestamps from data. The data in > > question is in both CSV and parquet format, and has dates encoded as > > strings in the following format: > > > > 1998-07-14T04:00:00 > > > > The issue I'm encountering is dealing with the literal T. The JODA > > instructions state that you can escape a literal with a single quote. > > IE: > > > > yyyy-MM-dd'T'hh:MM:00 > > > > However, the issue here is that since Drill does not allow double quotes, > > all these need to be escaped. > > > > yyyy-MM-dd\'T\'hh:MM:00 > > > > But... this just doesn't seem to work. I'm using the TO_TIMESTAMP() > > function. Any suggestions? > > Thanks, > > -- C >
