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

QSqlQuery with two bound parameters returns illegal result set

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 5.10.1
    • 5.10.0
    • SQL Support
    • None
    • Windows 10, Visual Studio 2017, Qt 5.10.0

      Also tested under Mac OS, Qt 5.10.0
    • 3e58f2b090661aab7302132cb2da661c8e227bc2

    Description

      Using a query with two bound parameters does not work - when replacing either one of them by hand in the query it works, but with both it fails.

      The MWE has a table with three entries - the task is to order them and select the "next" in line given the ordering. They are first ordered by column `sort_by`. When sort_by is the same, they should be ordered by `uid`.

      The QSqlQuery unexpectedly returns the initial input, which by query semantics can not be in the result set!

      This is a regression in Qt 5.10.0, as it works as expected in Qt 5.9.3.

      Attachments

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

        Activity

          People

            andysh Andy Shaw
            phiber Philipp Berger
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes