org.apache.calcite.runtime.CalciteException: Failed to encode '中文' in character set 'ISO-8859-1'
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 906
- Forks
- 219
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 2
Description
public void testTable() {
String sql = "select b, '中文' from test.t2 where b = a";
RelNode relNode = TestUtils.convertTable(sql);
RelToTrinoConverter relToTrinoConverter = new RelToTrinoConverter();
SqlNode expandedSql = relToTrinoConverter.convertToSqlNode(relNode);
System.out.println(expandedSql);
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the testTable reproduction, especially TestUtils.convertTable(sql) and RelToTrinoConverter.convertToSqlNode(relNode). Run the example containing the Chinese literal and trace where ISO-8859-1 encoding is applied. Done means the conversion completes without the CalciteException and preserves the literal in the resulting SQL node.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, sql
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100