Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Problem with encoding (INSERT) in oracle db on windows
Forum Updated to NodeBB v4.3 + New Features

Problem with encoding (INSERT) in oracle db on windows

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 2.1k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    dmcr
    wrote on last edited by
    #1

    Hello,
    I try to insert string with accent like "essais à" in an oracle 11g.
    @
    QSqlQuery query(db);
    query.prepare(QString("INSERT INTO TRADUCTION_TEXTE "
    "VALUES (:texte_original, 1, :traduction)") );

        query.bindValue( QString(":texte_original"), "essais à"  );
        query.bindValue( QString(":traduction"), "try to");
        query.exec();
    

    @

    but the insertion is not correct and i have some é caracters, due to incorrect encoding i guess (I am on windows)
    Does someone happen to have some idea to correct this?

    Thanks in advance.

    dmcr

    1 Reply Last reply
    0
    • K Offline
      K Offline
      koniar
      wrote on last edited by
      #2

      try query.bindValue( QString(":texte_original"), tr("essais ") );

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved