Previous Next

Thread: International Characters getting garbled between log parser and MSSql 2005

Last post 05-06-2008 6:27 PM by tyronewillingham. 1 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (2 items)

Sort Posts:

  • 05-01-2008, 10:43 PM

    International Characters getting garbled between log parser and MSSql 2005

    We have a mature solution in place using LogParser to read Exchange log files into out MSSql database.  Today, one of our clients alerted us to a problem they were having with french characters.  Specifically, "Héllo" read from the W3C formatted Exchange log file, turns into "héllo" in the SQL database.

    • Our solution is an asp file written in VBScript
    • The input format is W3C
    • The output format is SQL
    • The column in the table was originally a varchar(8000).  I have since changed it to an nvarchar(4000)
    • The column in the table has Collation = "SQL_Latin1_General_CP1_CI_AS"
    • I have manually set the iCodepage and oCodepage to 1252.

    I have tested the database, and I'm able to manually insert the "Héllo" directly from the log file.

    I set the output format to W3C and got the correct output.  I have not tried other output types.

    I've run out of roads to go down at this point.  Any thoughts?

    Thanks in advance
     


     

  • 05-06-2008, 6:27 PM In reply to

    Re: International Characters getting garbled between log parser and MSSql 2005

    After much tinkering, we determined that the exchange log files were being stored in UTF-8 format. By setting the input object's iCodepage to 65001 (UTF-8), the accented characters were correctly entered into the database. Hopefully this will answer someone else's question
Page 1 of 1 (2 items)
Page view counter