ClickHouse / clickhouse-odbc

ODBC driver for ClickHouse
https://clickhouse.tech
Apache License 2.0
245 stars 86 forks source link

ClickHouse ODBC Greek Characters #388

Open CostasBinary opened 2 years ago

CostasBinary commented 2 years ago

Hi team,

we are unable to retrieve Greek Characters from database with the ODBC driver. By using jdbc and dbeaver works fine on the same machine. Greek characters through odbc are unreadable. Since there is not setting in the parameters of the odbc can you advice us.

Kostas

traceon commented 2 years ago

Which platform are you using? Does your DSN point to Unicode version of the driver?

CostasBinary commented 2 years ago

We have created the odbc connection through windows (ODBC data source administrator) from windows 64bit then in our BI Tool which is called TARGIT BI we create a connection using the odbc connection from windows odbc

image

Thanks for helping Kostas

CostasBinary commented 2 years ago

Hi Denis, We have created the odbc connection through windows (ODBC data source administrator) from windows 64bit then in our BI Tool which is called TARGIT BI we create a connection using the odbc connection from windows odbc @.*** Thanks for helping K

From: Denis Glazachev @.> Sent: Thursday, January 13, 2022 6:23 PM To: ClickHouse/clickhouse-odbc @.> Cc: Costas Economakis @.>; Author @.> Subject: [Marketing Mail] Re: [ClickHouse/clickhouse-odbc] ClickHouse ODBC Greek Characters (Issue #388)

Which platform are you using? Does your DSN point to Unicode version of the driver?

— Reply to this email directly, view it on GitHubhttps://github.com/ClickHouse/clickhouse-odbc/issues/388#issuecomment-1012293905, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AXJCXKVYBLH3XSVAKJBZKDTUV335FANCNFSM5L3AKIDQ. Triage notifications on the go with GitHub Mobile for iOShttps://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Androidhttps://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you authored the thread.Message ID: @.**@.>>

traceon commented 2 years ago

Can you retrieve those characters in Excel, and see if that works. Here's how to do it Excel: https://altinity.com/blog/connecting-excel-to-clickhouse-using-the-windows-odbc-driver Go directly to Connecting to ClickHouse from Excel section and use your DSN in those steps.

CostasBinary commented 2 years ago

Hi Denis,

We have done the connection with excel it creates this file through the same odbc connection Excel works fine Greek characters work. Can you advise us ?

K

<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns="http://www.w3.org/TR/REC-html40">

targit_model_v1 tb_TRGMDL_Customers targit_model_v1 tb_TRGMDL_Customers Provider=MSDASQL.1;Persist Security Info=True;Extended Properties="DSN=ClickHouse;";Initial Catalog=targit_model_v1 Table `targit_model_v1`.`tb_TRGMDL_Customers` DSN=ClickHouse; SELECT * FROM `targit_model_v1`.`tb_TRGMDL_Customers`
   
 

From: Denis Glazachev @.> Sent: Thursday, January 13, 2022 9:24 PM To: ClickHouse/clickhouse-odbc @.> Cc: Costas Economakis @.>; Author @.> Subject: Re: [ClickHouse/clickhouse-odbc] ClickHouse ODBC Greek Characters (Issue #388)

Can you retrieve those characters in Excel, and see if that works. Here's how to do it Excel: https://altinity.com/blog/connecting-excel-to-clickhouse-using-the-windows-odbc-driver Go directly to Connecting to ClickHouse from Excel section and use your DSN in those steps.

— Reply to this email directly, view it on GitHubhttps://github.com/ClickHouse/clickhouse-odbc/issues/388#issuecomment-1012437617, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AXJCXKXNODKSAXILNW6XZ6DUV4RDNANCNFSM5L3AKIDQ. Triage notifications on the go with GitHub Mobile for iOShttps://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Androidhttps://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you authored the thread.Message ID: @.**@.>>

traceon commented 2 years ago

Excel works fine Greek characters work.

This suggests that the problem is most probably on the side of the client tool (TARGIT BI), and the driver passes letters as expected. Try making sure that the font has support for Greek alphabet, that the tool is able to handle all Unicode correctly, etc.

Also, try some other DB and ODBC driver with TARGIT BI and see if Greek letters are shown properly in that case.

CostasBinary commented 2 years ago

Hi Dennis,

We are using TARGIT BI for more than 15 years. We are handling data from MSSQL, MySQL, DB2 Postgres etc. through odbc connection all the time without having similar problem. Just a question is it possible to pass a parameter like this charset=utf-8 or similar on the connection string ? This is the connection string inside targit @.***;Persist Security Info=True;User ID=default;Data Source=ClickHouse;Initial Catalog=targit_model_v1 When we pop up the connection locale identifier is 1032 Language Code Description (informative) BCP 47 Code 1032 Greek el-GR

Is this the expected ?

@.***

Thanks once more Kostas

From: Denis Glazachev @.> Sent: Friday, January 14, 2022 1:18 PM To: ClickHouse/clickhouse-odbc @.> Cc: Costas Economakis @.>; Author @.> Subject: [Marketing Mail] Re: [ClickHouse/clickhouse-odbc] ClickHouse ODBC Greek Characters (Issue #388)

Excel works fine Greek characters work.

This suggests that the problem is most probably on the side of the client tool (TARGIT BI), and the driver passes letters as expected. Try making sure that the font has support for Greek alphabet, that the tool is able to handle all Unicode correctly, etc.

— Reply to this email directly, view it on GitHubhttps://github.com/ClickHouse/clickhouse-odbc/issues/388#issuecomment-1013031389, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AXJCXKW34UVBFNBX6UBBPUDUWAA53ANCNFSM5L3AKIDQ. Triage notifications on the go with GitHub Mobile for iOShttps://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Androidhttps://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you authored the thread.Message ID: @.**@.>>

traceon commented 2 years ago

Without being able to quickly reproduce, I won't be able to suggest anything else. The narrow-char string data is treated as UTF-8 by default.