Open liuyudong-pacvue opened 1 year ago
I found in com.clickhouse.jdbc.JdbcParameterizedQuery#parse method "ClickHouseUtils. IsQuote (ch)" will skip ['] and ["] in the middle of the content will not go to determine whether it will have[?] This makes it very difficult for me. Is there any good solution?
Hi @liuyudong-pacvue, it's expected that SQL parameter cannot be part of a string. Perhaps you can make the whole statement as a parameter?
Although it could be fun to play with jdbc table function, but please do NOT use it on production. This is because that it has issue in both design and implementation. Besides stability issue, the most severe one is probably ClickHouse/ClickHouse#36385.
Hi, If using the jdbc function is not recommended, is there a better way to perform joins and other related operations with other types of databases? If so, please let me know
Hi @SinceNovember, if you're talking about federated query on ClickHouse, perhaps url
table function is more reliable, although it requires you to implement a web service to bridge the query to corresponding database. If it's just about small amount of data for convenience as shown above, you may consider to issue separate query for external data, put it into an external table like below on ClickHouse for joining.
Thank you for your reply and I will refer to your comments!
Describe the bug
When I use mybatis, I need to find sqlserver data through the clickhouse jdbc function, but I found that sqlserver statements cannot use #{} to set parameters, but sql outside the jdbc function can use #{} to set parameters
Specifically, when I use the following SQL statement:
Error log
Configuration
Environment