Ask Your Question
1

DateTime conversion not working with milliseconds and timezone

asked 2020-01-12 11:00:23 -0600

rwetzeler gravatar image

I'm using this type converter to convert my string to a datetime.

image description

However this is giving this error:

image description

How could this be as the format looks to be appropriate.

Here is the full call stack:

image description

edit retag flag offensive close merge delete

Comments

https://ask.streamsets.com/question/6906/how-to-convert-string-into-datetime-by-using-expression-evaluator-input-record-is-in-iso8601utc-string/ this may help you what you're looking for.

strem_dev gravatar imagestrem_dev ( 2020-01-13 12:02:52 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2020-01-13 12:54:50 -0600

metadaddy gravatar image

Your date format specifies UTC ('Zulu time'), since it is terminated with the literal 'Z':

yyyy-MM-dd'T'HH:mm:sss.SSS'Z'

As it is, this format will only match strings ending with a Z. You should remove the quotes from the Z so that it is interpreted as the RFC 822 time zone:

yyyy-MM-dd'T'HH:mm:sss.SSSZ
edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2020-01-12 11:00:23 -0600

Seen: 19 times

Last updated: Jan 13