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

QPSQL reports an error when executing a query.

    XMLWordPrintable

Details

    • Bug
    • Resolution: Out of scope
    • P3: Somewhat important
    • Some future release
    • 4.5.2, 4.8.4
    • SQL Support
    • None

    Description

      When having the prepared QSqlQuery below for a postgresql 8.3.6 database.

      insert into user_records (service_number,event_number,stop_time) values (?,?,timestamp ? + time ?)

      then QPSQL always reports an error when executing this query:

      ERROR: syntax error at or near "("
      LINE 1: EXECUTE (93, 37, '2009-8-14 19:30:00.000', '02:00:00')
      ^
      QPSQL: Unable to create query

      However, when executing the query in the postgresql client it succeeds!

      client query:
      insert into user_records (service_number,event_number,stop_time) values (93,37,timestamp '2009-8-14 19:30:00.000' + time '02:00:00');

      Attachments

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

        Activity

          People

            mabrand Mark Brand
            sanonymous Nokia Qt Support (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes