提交 a8640fd5 authored 作者: Noel Grandin's avatar Noel Grandin 提交者: GitHub

Merge pull request #536 from marschall/timestamp-with-time-zone-type

Support TIMESTAMP_WITH_TIMEZONE 2014 JDBC type
......@@ -902,6 +902,8 @@ public class DataType {
return Value.TIME;
case Types.TIMESTAMP:
return Value.TIMESTAMP;
case 2014: // Types.TIMESTAMP_WITH_TIMEZONE
return Value.TIMESTAMP_TZ;
case Types.BLOB:
return Value.BLOB;
case Types.CLOB:
......
......@@ -682,6 +682,15 @@ public class TestPreparedStatement extends TestBase {
rs.next();
Object offsetDateTime2 = rs.getObject(1, LocalDateTimeUtils.getOffsetDateTimeClass());
assertEquals(offsetDateTime, offsetDateTime2);
assertFalse(rs.next());
rs.close();
prep.setObject(1, offsetDateTime, 2014); // Types.TIMESTAMP_WITH_TIMEZONE
rs = prep.executeQuery();
rs.next();
offsetDateTime2 = rs.getObject(1, LocalDateTimeUtils.getOffsetDateTimeClass());
assertEquals(offsetDateTime, offsetDateTime2);
assertFalse(rs.next());
rs.close();
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论