Re: geometry type support problem

2021-06-22 Thread tonytao
o it’s not surprising that there are some interoperability issues. Can you please log a JIRA case for this issue? Julian On Jun 22, 2021, at 2:47 AM, tonytao wrote: hi folks, I'm using calcite with postgis, and found the support of geometry type is not very good. Firstly, geometry was not

geometry type support problem

2021-06-22 Thread tonytao
hi folks, I'm using calcite with postgis, and found the support of geometry type is not very good. Firstly,  geometry was not added to enum "SqlTypeName" as a jdbc type, geometry type  read from postgresql jdbc will convert to ANY type. Since 1.27.0, the hepPlanner will add a

how to enable spatial when sql validate

2021-04-02 Thread tonytao
hi , I'm trying to parse sql with org.apache.calcite.tools.Planner, but when validate,it throw exception: Exception in thread "main" org.apache.calcite.tools.ValidationException: org.apache.calcite.runtime.CalciteContextException: From line 1, column 8 to line 1, column 30: No match found

Re: [Bug Report]RelToSqlConverter stack error in 1.24-1.26

2020-12-08 Thread tonytao
method *visitRoot* work well.Ichange my code to :         RelToSqlConverter converter = new RelToSqlConverter(PostgresqlSqlDialect.DEFAULT);         SqlSelect select = converter.visitRoot(project1).asSelect(); fixed the problem. Thank you again! On 12/8/20 4:09 PM, tonytao wrote: Tkansks,I

Re: [Bug Report]RelToSqlConverter stack error in 1.24-1.26

2020-12-08 Thread tonytao
tonytao wrote: Hi folks, I found a RelToSqlConverter bug existed in 1.24-1.26. I has a logical plan as below: LogicalProject(id=[$0], CAST=[CAST($1):DATE]) LogicalFilter(condition=[AND(<($1, 2011-12-01 00:00:00), >($0, 100))]) JdbcTableScan(table=[[

[Bug Report]RelToSqlConverter stack error in 1.24-1.26

2020-12-07 Thread tonytao
Hi folks, I found a RelToSqlConverter bug existed in 1.24-1.26. I has a logical plan as below:   LogicalProject(id=[$0], CAST=[CAST($1):DATE])     LogicalFilter(condition=[AND(<($1, 2011-12-01 00:00:00), >($0, 100))])   JdbcTableScan(table=[[public, testdata]]) when concert

Re: RelToSqlConverter NullPointerException

2020-08-10 Thread tonytao
Sorry, the attached file was wrong,please ignore it. I upload a new file. On 8/10/20 4:38 PM, tonytao wrote: hi team, I met a NullPointerException when I used calcite 1.24.0 to convert a relNode to sqlNode. The trace: java.lang.NullPointerException     at java.base

Re: Exception:Catch clause is unreachable

2020-07-24 Thread tonytao
contribute the fix if they want to. Best, Danny Chan 在 2020年7月24日 +0800 PM2:05,tonytao ,写道: I had found the empty result was happened at select validate,it could not get column datatype from jdbc connection metadata . I changed the query,it throw exception about "Column 'TS' not found in any

Re: Exception:Catch clause is unreachable

2020-07-24 Thread tonytao
citeJdbc41Factory$CalciteJdbc41Statement(AvaticaStatement).executeQuery(String) line: 227     App5.main(String[]) line: 45 On 7/24/20 9:20 AM, tonytao wrote: Thanks Julian! I had queried on result metadata,it has 2 columns. code:         ResultSet rs = stmt.ex

Re: Exception:Catch clause is unreachable

2020-07-23 Thread tonytao
2020, at 2:18 AM, tonytao wrote: Thanks again,danny! It's hard to set the appropriate breakpoint position.:-). I'll check the jdbc api whether it returned correct results. Best regards! On 7/23/20 4:44 PM, Danny Chan wrote: In general, Calcite use janino to compile the generated Java

Re: Exception:Catch clause is unreachable

2020-07-23 Thread tonytao
. Best, Danny Chan 在 2020年7月23日 +0800 PM4:05,tonytao ,写道: hi Danny, Thank you for your kindly help. Attach is the generated code.but I had no idea how this file generated or fix the bug. I'm sorry that I could not receive your reply with my work email account,so I replied with my personal

Re: Re: Exception:Catch clause is unreachable

2020-07-23 Thread tonytao
hi Danny, Thank you for your kindly help. Attach is the generated code.but I had no idea how this file generated or fix the bug. I'm sorry that I could not receive your reply with my work email account,so I replied with my personal account. errlog: at

Exception:Catch clause is unreachable

2020-07-21 Thread tonytao
hi folks, I had met a compiler error on calcite-core:1.23.0,jdk version is :openjdk version "11.0.7" 2020-04-14. Here is the error log,is this a bug? Exception in thread "main" java.sql.SQLException: Error while executing SQL "select * from test.t": Error while compiling generated Java