Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-96616

QODBC-DB2 Unicode support is not recognised

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • 6.5.1, 6.6.0
    • 5.15.6
    • SQL Support
    • None
    • ODBC with IBM i Access ODBC Driver - Windows
    • All
    • f19320748 (dev), b8f140b70 (6.5)

    Description

      In the QODBCDriverPrivate::checkUnicode() method, the query QLatin1String("select 'test'")) attempts to determine whether the database supports Unicode. 
      SELECT without FROM is not standard-compliant. DB2 and Oracle do not allow a query without FROM.

      Possible solution:
      At least DB2 supports the values('test') statement.
      Possible solution (but not the nicest):
      r = SQLExecDirect(hStmt, toSQLTCHAR(QLatin1String("select 'test'")).data(), SQL_NTS); if(r != SQL_SUCCESS) r = SQLExecDirect(hStmt, toSQLTCHAR(QLatin1String("values('test')").data(), SQL_NTS);

       

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              mabrand Mark Brand
              sebastianst Sebastian Stadelmann
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes