Github user adrian-wang commented on the pull request:
https://github.com/apache/spark/pull/3732#issuecomment-68815238
For oracle's doc about `java.sql.Date`, In
https://docs.oracle.com/javase/6/docs/api/java/sql/Date.html
To conform with the definition of SQL DATE, the millisecond values wrapped
by a java.sql.Date instance must be 'normalized' by setting the hours, minutes,
seconds, and milliseconds to zero in the particular time zone with which the
instance is associated.
For SQL-92 spec, http://www.contrib.andrew.cmu.edu/~shadow/sql/sql1992.txt
In page 111,
2) For a <datetime type>,
Case:
a) If DATE is specified, then the data type contains the <date-
time field>s years, months, and days.
The spec also clarifies that the definition is taken from
ISO-8601[http://www.w3.org/TR/NOTE-datetime], in which it says,
Complete date:
YYYY-MM-DD (eg 1997-07-16)
Hence, the time part of `java.sql.Date` is not necessary. I think that
simply results from the inheritance of the same base type, namely
`java.util.Date`, with `java.sql.Timestamp`
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]