drill-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Herman Tan <her...@redcubesg.com>
Subject to_date() string to date conversion ERROR
Date Mon, 01 Oct 2018 07:55:56 GMT
Hi,

I have a very puzzling error.
Try the following SQL statements.

What is the problem with '1982/01/01 00:01:00.000000000'?
Error message: Illegal instant due to time zone offset transition

select to_date('1981/12/31 00:00:00.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- pass
from (values(1))

select to_date('1981/12/31 11:59:59.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- pass
from (values(1))

select to_date('1982/01/01 00:00:00.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- fail
from (values(1))

select to_date('1982/01/01 00:00:01.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- fail
from (values(1))

select to_date('1982/01/01 00:01:00.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- fail
from (values(1))

select to_date('1982/01/01 01:00:00.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- pass
from (values(1))

select to_date('1982/01/02 00:00:00.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- pass
from (values(1))

select to_date('1983/01/01 00:00:00.000000000','yyyy/MM/dd
HH:mm:ss.SSSSSSSSS') -- pass
from (values(1))

Herman

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message