• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Query Microsoft Text Driver (*.txt; *.csv) ODBCJT32 Specify charset

Shreedhar

New Member
Gurus,

I am using Microsoft Text Driver (*.txt; *.csv) ODBCJT32 to import CSV which has accented characters (ŠŽšžŸÀÁÂÃÄÅÇÈÉÊËÌ), currently the query result appears as ASCII characters and so the accented characters appears as JUNK chars(ÅŽšžŸÀÁÂÃÄÃ), but I want the accented characters to appear as it is in the CSV file.

Is is possible to specify charset (ANSI, UTF8) while querying CSV sheet.

Would be grateful for any insight to solve this issue.

Thanks for your time.

Best Regards, Shreedhar
 
Since text files do not have schema info within the file itself you will need to create schema.ini file in the same folder containing text file.
In there you specify CharacterSet to Unicode.

See links for more details.
http://teradataforum.com/teradata/20041029_083023.htm
https://chandoo.org/forum/threads/ado-connection-csv-issue-with-mixed-data-type.34097/
Thanks Chihiro...
Works well if the source file has the same encoding but, my current scenario data file comes some times with ANSI, UTF8, UTF-8-BOM. :(

Please share suggestions to handle this scenario efficiently...

Thanks for your help & suggestions
 
Since text files do not have schema info within the file itself you will need to create schema.ini file in the same folder containing text file.
In there you specify CharacterSet to Unicode.

See links for more details.
http://teradataforum.com/teradata/20041029_083023.htm
https://chandoo.org/forum/threads/ado-connection-csv-issue-with-mixed-data-type.34097/


Chihiro,

I used Microsoft.Jet.OLEDB.4.0 driver as an alternate to solve the issue. This driver has extended properties that supports CharacterSet parameter.

Thanks for your help
 
Back
Top