Hortonworks data platform ExecuteSQL是否不选择具有日期时间偏移值的表?

Hortonworks data platform ExecuteSQL是否不选择具有日期时间偏移值的表?,hortonworks-data-platform,apache-nifi,Hortonworks Data Platform,Apache Nifi,我已经创建了一个具有数据类型-dateTimeOffset值的单列表,并插入了一些值 create table dto (dto datetimeoffset(7)) insert into dto values (GETDATE()) -- inserts date and time with 0 offset insert into dto values (SYSDATETIMEOFFSET()) -- current date time and offset insert into dto

我已经创建了一个具有数据类型-dateTimeOffset值的单列表,并插入了一些值

create table dto (dto datetimeoffset(7))
insert into dto values (GETDATE()) -- inserts date and time with 0 offset
insert into dto values (SYSDATETIMEOFFSET()) -- current date time and offset
insert into dto values ('20131114 08:54:00 +10:00') -- manual way
在Nifi中,我在Execute SQL中指定了Select*from dto查询

它显示以下错误

java.lang.IllegalArgumentException: createSchema: Unknown SQL type -155 cannot be converted to Avro type
若我将该列更改为dateTime,那个么ExecuteSQL将正确运行,但它在DateTimeOffset列中不起作用

谢谢你的帮助


非常感谢

datetimeoffset是一个,不受支持的ExecuteSQL支持。您可以尝试将datetimeoffset字段强制转换为其他一些标准类型,如datetime,如上所述。

我创建了一个自定义处理器,并修改了jdbcommon.java类以包含SQL Server的datetimeoffset。这只是一行代码。我会试着看看我是否能让他们在正式回购协议中合并这一点

这是我的jdbccomon.java的一部分:

案例时间戳: 带有\u时区的案例时间戳\u: case-101://带有时区的Oracle时间戳 案例-102://带有本地时区的Oracle时间戳 案例-155://SQL Server的DATETIMEOFFSET options.useLogicalTypes ? u、 typeLogicalTypes.timestampMillis.addToSchemaSchemaBuilder.builder.longType :u.stringType; 打破
谢谢Mattyb的回复