Bug 6582

Summary: CSV load only support UTF-8 encoding
Product: SQL Reporter: Guillaume de GENTILE <gentile_g>
Component: allAssignee: SQL devs <bugs-sql>
Status: NEW ---    
Severity: enhancement CC: martin.van.dinther
Priority: Normal    
Version: 11.27.9 (Jul2017-SP2)   
Hardware: All   
OS: All   

Description Guillaume de GENTILE 2018-04-18 14:58:23 CEST
User-Agent:       Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.181 Safari/537.36
Build Identifier: 

Is it possible to support other encoding than UTF-8 with Java memory database

Reproducible: Always

Actual Results:  
Process failed to parse special characters if file encoding is not "UTF-8"

Expected Results:  
Requirement is to be able to specify the input file encoding.

I see 2 possibilities:

1) Set default encoding in the Database URL.
<database url>?charset=ISO-8859-1
<database url>?encoding=ISO-8859-1

2) Enhance CSV load:
COPY INTO table123 from 'sdsdsdsd.csv' CHARSET ISO-8859-1
COPY INTO table123 from 'sdsdsdsd.csv' ENCODING ISO-8859-1

Thanks and regards,
Comment 1 Martin van Dinther cwiconfidential 2018-04-18 18:09:31 CEST
Changed the Product label value from Client interfaces/JDBC into SQL
as this is an enhencement request to: extend the "COPY INTO <table> FROM <file>" SQL command, which currently only supports files with data in UTF-8 encoding.