-
- Downloads
[SPARK-20557][SQL] Support JDBC data type Time with Time Zone
### What changes were proposed in this pull request? This PR is to support JDBC data type TIME WITH TIME ZONE. It can be converted to TIMESTAMP In addition, before this PR, for unsupported data types, we simply output the type number instead of the type name. ``` java.sql.SQLException: Unsupported type 2014 ``` After this PR, the message is like ``` java.sql.SQLException: Unsupported type TIMESTAMP_WITH_TIMEZONE ``` - Also upgrade the H2 version to `1.4.195` which has the type fix for "TIMESTAMP WITH TIMEZONE". However, it is not fully supported. Thus, we capture the exception, but we still need it to partially test the support of "TIMESTAMP WITH TIMEZONE", because Docker tests are not regularly run. ### How was this patch tested? Added test cases. Author: Xiao Li <gatorsmile@gmail.com> Closes #17835 from gatorsmile/h2.
Showing
- external/docker-integration-tests/src/test/scala/org/apache/spark/sql/jdbc/OracleIntegrationSuite.scala 1 addition, 1 deletion...la/org/apache/spark/sql/jdbc/OracleIntegrationSuite.scala
- external/docker-integration-tests/src/test/scala/org/apache/spark/sql/jdbc/PostgresIntegrationSuite.scala 15 additions, 0 deletions.../org/apache/spark/sql/jdbc/PostgresIntegrationSuite.scala
- sql/core/pom.xml 1 addition, 1 deletionsql/core/pom.xml
- sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/jdbc/JdbcUtils.scala 9 additions, 3 deletions...ache/spark/sql/execution/datasources/jdbc/JdbcUtils.scala
- sql/core/src/main/scala/org/apache/spark/sql/internal/CatalogImpl.scala 0 additions, 1 deletion...ain/scala/org/apache/spark/sql/internal/CatalogImpl.scala
- sql/core/src/test/scala/org/apache/spark/sql/jdbc/JDBCSuite.scala 22 additions, 2 deletions.../src/test/scala/org/apache/spark/sql/jdbc/JDBCSuite.scala
Loading
Please register or sign in to comment