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

Incomplete execution of SQL statements with QSQLITE driver

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 4.8.x, 5.0.0
    • 4.7.4
    • SQL Support
    • None

    Description

      This code will create only "table_1" table:

      QSqlDatabase db = QSqlDatabase::addDatabase( "QSQLITE" );
      QSqlQuery query( db );
      query.exec( "CREATE TABLE table_1 (a); CREATE TABLE table_2 (b);" );

      As i have found from the qsql_sqlite.cpp it happens because QSQLiteResult::prepare(const QString &query) ignores the fifth argument of sqlite3_prepare16_v2() which returns unprepared part of the query.

      Attachments

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

        Activity

          People

            zhongle honglei zhang
            p-himik Eugene Pakhomov
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes