-
Notifications
You must be signed in to change notification settings - Fork 962
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
您好,请问一下我操作java API获取表字段类型的时候有问题? (How to get series data type using Java API) #1461
Comments
这个应该没维护了 现在获取结果集列名的方法,JDBC 和 Session 不太一样,可以参考 推荐使用 Session 的 |
收到,感谢您的回复,我现在的需求是要提前获取列的类型,然后再插入数据的时候用preparedStatement指定类型,请问有这块的指导资料吗? |
Not maintained?? don't we have UT to cover it? 我们这个接口没有再维护了?JDBC的接口还是应该维护吧。。
看下这个文档的show timeseries语法: https://iotdb.apache.org/UserGuide/Master/Operation%20Manual/SQL%20Reference.html 此外session有个API是fetchMetadata 应该也可以。 |
preparedStatement 最近没维护,不确定能不能正常工作。。如果每次写入都要查一下元数据会比较慢,可以用 Session 的 insertRecords 接口。String values 这个接口会在服务器端自动推断类型,只要提前注册好序列就可以了。 如果想写入的时候指定类型,可以查出来类型在客户端缓存,这个查询可以用 show timeseries |
收到, @jixuan1989 @qiaojialin 感谢回复!感觉咱们现在主要维护session这块了,我看一下,能提供一下交流群吗,这样方便交流 |
ResultSetMetaData metaData = resultSet.getMetaData(); |
// 当 columnPattern 为"root.*"的时候,可以获得所有的列名
// 当columnPattern为某一列(如"root.sgcc.wf03.wt01.temperature")的时候,可以获得
该列的数据类型
public ResultSet getColumns(String catalog, String schemaPattern, String
columnPattern, String deltaObjectPattern)
请问一下咱们这个版本还有维护这个API吗?我这边获取的resultset为null,能帮忙看看吗,谢谢了
The text was updated successfully, but these errors were encountered: