Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2012
    Posts
    1

    Unanswered: Insert data via ODBC to DB (AS400/DB2) problem

    Hello.

    I've got a problem when I try to insert record into
    Physicl file (AS400) that CCSID is 838.

    I used SQL statement on VB.net with ODBC connection
    "INSERT INTO ..... VALUES (parm1, parm2, parm3)"

    *parm3 is containning thai language string

    Statement SQL run completely but when I query result record
    (via emulator workstation accessing AS400 OS)

    I found green tap on the field that I was insert thai language
    It can not translate from thai language in my application (VB.NET)
    into database on AS400

    How can I fix this problem?

  2. #2
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    The intuitive answers would be to add code within your .NET app to handle UTF-8 encoding for the column that stores the Thai text. This will often make the string longer, so it might require other changes (like changing the column DDL to make it longer).

    Another approach would be to ensure that your application really does pass Unicode to the database (don't assume this, confirm it) then change the DDL for the column to allow it to store Unicode data.

    -PatP
    In theory, theory and practice are identical. In practice, theory and practice are unrelated.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •