TDengine icon indicating copy to clipboard operation
TDengine copied to clipboard

supertable creation fails with batchfetch=true but succeeds without this parameter

Open jsk970 opened this issue 1 year ago • 3 comments

使用JdbcTemplate创建超级表。 代码片段: PreparedStatementSetter preparedStatementSetter = ps ->{ ps.setString(1,superTableName); }; jdbcTemplate.update(sql.toString(), preparedStatementSetter);

image

预编译sql: CREATE STABLE IF NOT EXISTS ? (ts timestamp,int_v int,float_v float,double_v double,bool_v bool,binary_v binary(1024),extend_json nchar(4000)) tags (device_uuid binary(1024))

版本信息: 服务版本:[tdengine/tdengine:3.2.3.0] 驱动版本:taos-jdbcdriver 3.2.10

异常信息: Caused by: java.sql.SQLException: (0x2600):syntax error near "? (ts timestamp,int_v int,float_v float,double_v double,bool_v bool,binary_v binary(1024),extend_json nchar(4000)) tags (device_uuid binary(1024))" at com.taosdata.jdbc.ws.TSWSPreparedStatement.executeUpdate(TSWSPreparedStatement.java:224) at com.alibaba.druid.filter.FilterChainImpl.preparedStatement_executeUpdate(FilterChainImpl.java:3201) at com.alibaba.druid.filter.FilterAdapter.preparedStatement_executeUpdate(FilterAdapter.java:1091) at com.alibaba.druid.filter.FilterEventAdapter.preparedStatement_executeUpdate(FilterEventAdapter.java:491) at com.alibaba.druid.filter.FilterChainImpl.preparedStatement_executeUpdate(FilterChainImpl.java:3199) at com.alibaba.druid.proxy.jdbc.PreparedStatementProxyImpl.executeUpdate(PreparedStatementProxyImpl.java:194) at com.alibaba.druid.pool.DruidPooledPreparedStatement.executeUpdate(DruidPooledPreparedStatement.java:256) at org.springframework.jdbc.core.JdbcTemplate.lambda$update$0(JdbcTemplate.java:867) at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:617) ... 44 more

jsk970 avatar Apr 30 '24 03:04 jsk970

image

jsk970 avatar Apr 30 '24 05:04 jsk970

使用官方示例WSParameterBindingFullDemo 针对动态参数表名创建超级表 目前 异常报错 (0x22a):Stmt API usage error image

jsk970 avatar Apr 30 '24 07:04 jsk970

收到,我们看下

yu285 avatar May 24 '24 07:05 yu285