[
https://issues.apache.org/jira/browse/CALCITE-4690?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Stamatis Zampetakis resolved CALCITE-4690.
------------------------------------------
Resolution: Fixed
Fixed in
[1da412aa26fe374714bdac29f5d51adf400c8f72|https://github.com/apache/calcite/commit/1da412aa26fe374714bdac29f5d51adf400c8f72].
Thanks for the review [~nobigo]!
> Error when executing query with CHARACTER SET in Redshift
> ---------------------------------------------------------
>
> Key: CALCITE-4690
> URL: https://issues.apache.org/jira/browse/CALCITE-4690
> Project: Calcite
> Issue Type: Bug
> Components: core, jdbc-adapter
> Affects Versions: 1.27.0
> Reporter: Stamatis Zampetakis
> Assignee: Stamatis Zampetakis
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.28.0
>
> Time Spent: 50m
> Remaining Estimate: 0h
>
> Redshift does not support character sets in [data
> types|https://docs.aws.amazon.com/redshift/latest/dg/r_Character_types.html].
> In fact it seems that it only supports
> [UTF-8|https://docs.aws.amazon.com/redshift/latest/dg/multi-byte-character-load-errors.html].
> As a result any appearance of the CHARACTER SET clause in a query leads to
> errors.
> {code:sql}
> select cast (col1 as varchar(3) CHARACTER SET "ISO-8859-1") from test;
> {code}
> {noformat}
> Error: ERROR: type "pg_catalog.varchar_iso-8859-1" does not exist
> (state=42704,code=0)
> {noformat}
> Even if {{CHARACTER SET}} clause is not explicitly present in the original
> query it might appear in the generated SQL via {{RelToSqlConverter}} due to
> casts or other operations.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)