JDBC data import and data encoding (UTF-8/16)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-20-2010 01:54 AM
Hi,
I'm importing data from our SQL server 2008 database and I got problem with charset encoding.
I'm using MID server to connect and send back data from our SQL server.
Depending on the content of the query result, the returned data is encoded differently, and accentuated characters becomes unreadable (see attachment) :
- "CÃÆ’ ©dric" ---> UTF-8 that I'm able to convert using a little script (google is my friend)
- C����dric ---> probably UTF-16 but I'm not able to convert it, as none of the algorythms that have found can work on this.
I've tryed to find solution on the three side of the problem :
- SQL server: nothing let me specify the format used for queries results, exepted the "N''Value" notation or UNICODE('value'). This will send UTF-16 data that I'm not able to handle in service-now.
- MID server / JDBC. I've tryed to use standard parameter for JDBC connection (connection URL), but, as far as I can find on microsoft site, they are not parsed by the driver :
* I haven't found a wait to configure table/data encoding in config.xml
* useUnicode=true
* characterEncoding=UTF-8
* charset=UTF-8
* sendStringAsUnicode=true <-- according the microsoft documentation, this is the only one that is usable, but does not avec the format used for replies
* Encondig=UTF-8
- Service now itself
* Script for UTF-8 convertion <-- working
* Script for UTF-16 convertion <-- not working working
* charset=UTF-8 in data source parameters (like for CSV) : no effect
* I haven't found a way to configure table/data encoding
Feel free to contact me if you need more details.
Regards,
Philippe
- Labels:
-
Service Mapping
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-01-2011 05:08 AM
This seems to be solved with June11 patch 2