summaryrefslogtreecommitdiffstats
path: root/src/plugins/sqldrivers/odbc/qsql_odbc.cpp
Commit message (Collapse)AuthorAgeFilesLines
* QODBC: Fix crash when a prepared statement is deleted after the db was removedChristian Ehrlicher2019-10-151-5/+5
| | | | | | | | | | When a prepared statement is still alive after the database was removed with QSqlDatabase::removeDatabase(), the cleanup routine is trying to access the driver which is no longer alive which results in a crash. Fixes: QTBUG-79019 Change-Id: I4630e3b947a12b23ed062f015abc373fc0e246c1 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Fix a couple of unused QStringsSergio Martins2018-12-101-1/+1
| | | | | | | | | This is needed so we can add Q_WARN_UNUSED to QString. The xcb one might even be a bug. Change-Id: Ia2d2563bdd10aa747014410df4990597969f4634 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* ODBC: Correctly check if the field is within the fieldCache rangeAndy Shaw2018-09-131-1/+1
| | | | | | | | | This was found while running the ODBC tests. tst_QSqlQuery::isNull() accounts for this already. Change-Id: Idf99a85396d7aa4e69b89467f873b105ef946f7f Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* ODBC: Remove the trailing \0 in the case of a non unicode stringAndy Shaw2018-09-111-3/+6
| | | | | | | | | | | | | | Some ODBC drivers, such as old Informix ODBC drivers will incorrectly include a trailing \0 in a string when this should not exist. For unicode strings this was already accounted for, but for non-unicode ones this was not covered. The change also fixes up the comments a bit to make this clearer and also added one for the unicode case. Task-number: QTBUG-62406 Change-Id: Id932a58d9e5fdff2f4d1aacf8cc9fdaeb34f95f4 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* SQL plugins: Fix warnings about deprecated constructor of QSqlErrorFriedemann Kleint2018-01-101-2/+4
| | | | | | | | Use the constructor taking a string and convert number unless it is -1. Change-Id: I18d1ba2c8e0d3f4af01b7955863967f75051746b Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Replace Q_DECL_OVERRIDE with override where possibleKevin Funk2017-09-191-18/+18
| | | | | | | | | | | | | | | | Remaining uses of Q_DECL_OVERRIDE are in: src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.cpp doc/global/qt-cpp-defines.qdocconf (definition and documentation of Q_DECL_OVERRIDE) tests/manual/qcursor/qcursorhighdpi/main.cpp (a test executable compilable both under Qt4 and Qt5) Change-Id: Ib9b05d829add69e98a86238274b6a1fcb19b49ba Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* QSqlField: Add a means to see what the tablename is for a given fieldAndy Shaw2017-07-121-0/+7
| | | | | | | | | | | | When you are using a query that pulls from a number of different tables then it can be ambiguous as to which table a particular field belongs to. So this will make it possible to determine the table that a given field belongs to if it is set. Task-number: QTBUG-7170 Change-Id: I49b7890c0523d81272a153df3860df800ff853d5 Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Always compile sql drivers as pluginsLars Knoll2016-04-071-0/+2639
Compiling the drivers into Qt Sql does not make a lot of sense anymore, as we handle plugins well enough in the build system these days. [ChangeLog][Build system] SQL drivers are now always compiled as plugins. Change-Id: I364b82a480849399d1fafe4b20e9f08922569260 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>