| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In it's current state the plugin is not buildable. This patch
tries to address that by fixing those issues. They include:
- Drag QOCIResultPrivate into the namespace and forward declare as
class. It is defined as class and this should stay in sync.
- Mark the overwritten members with 'override'.
- add missing declaration for 'fetchNext'
- Make the pimpl a proper Qt-dPtr by using Q_DECLARE_PRIVATE and rename
it into 'd_ptr' so that we can use the 'Q_D' macro.
- Remove the function call to 'isCursor'. This bool is member variable
of the class.
- Remove a '+' in front of 'internal_prepare' definition.
- Remove the 'QOCIDriverPrivate' argument to the ctor. The initial one
didn't had it and no other definition was provided.
Amends: 82681fd8a2af1113da5bd13875ba71c1efd45afb
Change-Id: I5b5042730b0decb440795bbb627c2cacc098594e
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Move the QOCIResult implementation of QSqlCachedResult into the private
qsql_oci_p.h header, and register it as a meta type that we can pass
through QVariant. Add a field that indicates whether that results
represents a cursor variable, and bind it to the statement handle if so.
Fixes: QTBUG-166
Fixes: QTBUG-44643
Change-Id: Iafbf5474ad7efc6d24eb52a5c5a1b3d2b6842387
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Either make them static or declare them in a header. We want them to be
static wherever possible, in order to reduce the number of visible
symbols. If they can't be static, however, they should at least be
declared in only one place.
Task-number: QTBUG-67692
Change-Id: I6f3b596ed4f0adc9873dd0a5f54f055a991a6207
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[ChangeLog][CMake] Added the configure feature 'force-system-libs'.
Enabling this feature enables every 'system-foolib' feature, and the
system-provided 3rdparty library foo will be used. If the library is not
found, an error is yielded. Also added the analogous
'force-bundled-libs' feature that enforces the usage of bundled 3rdparty
libs.
[ChangeLog][CMake] The configure script gained the options
-force-system-libs and -force-bundled-libs that control the same-named
configure features.
Since we now need a way to mark a feature as "controlling the usage of a
system 3rdparty library", we added the SYSTEM_LIBRARY feature to the
qt_feature command. Patches that add this argument to qt_feature calls
in other repositories follow.
Fixes: QTBUG-96910
Change-Id: I5c411409ea5f3f6425b6bed6fa00d10eddbc366c
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
| |
|
|
|
|
|
| |
Pick-to: 6.8
Task-number: QTBUG-122899
Change-Id: I2eb70ca4d52e30c8e15ca7b350df6965d93732f8
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Simplify date/time conversion by using QTime::fromMSecsSinceStartOfDay()
/ QTime::toMSecsSinceStartOfDay() and avoiding some intermediate
variables.
Pick-to: 6.8
Change-Id: I16e673405a347417866cdf100a13d817c1b17ff8
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
| |
Amends 4b0b41ec3b362715012f8c771b72c4704f8170f3.
Pick-to: 6.8
Change-Id: If51e22fb9b19755a0d8f222f8c0044563f8c55f8
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
| |
|
|
|
|
|
|
| |
Make some untranslated texts translatable.
Pick-to: 6.8
Change-Id: I636cdcaff749d6770d82095e4a2381097f83ed2c
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Make sure that QByteArray does not detach when not needed and avoid some
copies by using QByteArray::fromRawData().
Pick-to: 6.8
Change-Id: I4454a3113c6bd1fe30b404af091f5cc0f904f78a
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
Pass 'const char *' when the string doesn't get modified.
Pick-to: 6.8
Change-Id: I8b2e06b027362debcd81282dc3123235a7e643a3
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
The lower bit of the sqltype is used to express NULL values and needs
therefore masked out. Do this before the acutal operations for better
readability/debugability.
Pick-to: 6.8
Change-Id: I71ee97f4c38241ccc9804562e2826ce9b53567ba
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
Cleanup the code by replacing repeated access to sqlda->sqlvar[] with a
temporary (const) ref to enhance readability and avoid repeated lookups.
Pick-to: 6.8
Change-Id: I716812f4446bac7fb3e92bc6fbb099845836624f
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Andreas Bacher <andi.bacher@outlook.com>
|
| |
|
|
|
|
|
|
|
| |
Cache the return value of QIBaseResult::record() to avoid the recreation
(e.g. when using QSqlQuery::value(QString) instead index-based ones).
Pick-to: 6.8
Change-Id: I88568d99ba96e19ae6b661d058e7709ebc5ef2a2
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
| |
... instead Q_CC_MSVC to be in sync with qlocale_tools_p.h and avoid
compiler erros when used with msvc versions not providing int128
support.
Pick-to: 6.8
Change-Id: Ia2166a6260a9340a5e5bbca3f46c3b77a9f8d50d
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Since name clashes between logging categories are so common, having a
way to explicitly avoid them is important. So far, we are depending on
internals of Q_LOGGING_CATEGORY to place the "static" in the right
location. That's less than ideal.
Task-number: QTBUG-67692
Change-Id: Ifeda5297d1d1220a57118b3bf7c7310e4ddd4f93
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The previous patch missed the handling of SQL_INT128 in
qIBaseTypeName2().
This amends 373ae6cbd24cf0ddbed453e14b1f683e76c92bb5
Pick-to: 6.8
Change-Id: I646bd5af23c14761195f9c1089dc4cbbe2e94790
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Andreas Bacher <andi.bacher@outlook.com>
|
| |
|
|
|
| |
Change-Id: I6a6f4d4e4c2e4fa8b83078ee5864cc923265ac2e
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implement partial support for SQL_INT128 datatype which is used for
DECIMAL/NUMERIC columns with a precision > 18. This support is only
available when QT_SUPPORTS_INT128 is defined and for MSVC.
Binding values to columns which need SQL_INT128 is supported but
numbers given as QString will be converted to doubles even if
QSql::HighPrecision is set.
[ChangeLog][SQL][IBASE] Added support for SQL_INT128 datatype.
Task-number: QTBUG-124575
Change-Id: If3fb1eb0f19dc60f000d163f3bf45da7acb08c87
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Andreas Bacher <andi.bacher@outlook.com>
|
| |
|
|
|
|
|
| |
Factor out setting numeric values for better readability.
Change-Id: I8980c63e87934e3bc3777897e9cd42aef17caf51
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
When connecting to an old Firebird instence with a Qt Firebird plugin
linked against Firebird >= 4 the timezone table is not available and
therefore open() will fail. Therefore downgrade the non-existence of
this table to a qCInfo().
Fixes: QTBUG-125467
Change-Id: Iae6d110bc2a48b5b90ffb9cb38f3fba60f30770f
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Andreas Bacher <andi.bacher@outlook.com>
|
| |
|
|
|
|
|
|
| |
Looks like the CI does not compile the IBase/Firebird plugin so this
compile error slipped through.
Change-Id: I2e20088e10baa91f2e1e5e2b5656dfb7bdf42896
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
|
| |
|
|
|
|
|
|
| |
Move the calculation of the decimal scale into own function and preserve
HighPrecision string values by not converting them into doubles before.
Change-Id: I839923189e9f6b1f8fb9ce234c987423703b79bf
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
Print a warning when we encounter an unsupported data type.
Pick-to: 6.7 6.5
Change-Id: If35ac4dfdf29e555ec406f592c1001b5e16f8ff2
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
... instead three times in a row.
Pick-to: 6.7
Change-Id: If08b4c092cfb5b7d224f9a94afb7d395ce2b2eca
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
| |
Use the categorized logger qt.sql.ibase
Change-Id: Id7cdc54b8b01ee5af0526e3c522c2511697380d3
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
| |
Use the categorized logger qt.sql.oci
Change-Id: Ib143cfa3136a7382adbabfe4bc421b94e2a25bda
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
Use the categorized logger qt.sql.mimer
Change-Id: I1b0d149a1a6317eec3b821dee99d952ef1000c28
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Fredrik Ålund <fredrik.alund@mimer.com>
|
| |
|
|
|
|
|
|
|
| |
To avoid usage errors like fixed with
7e5a0b54f0737986b6716bfce0a43eba2e62aae0
Pick-to: 6.7
Change-Id: I33af9721a04e80541c027fa6da8630070a5957ac
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
.. by playing it safe and taking the QVariant by copy
Pick-to: 6.7 6.5
Change-Id: I24e0507a912388b7fb17e838a22e8d4c449bcf5b
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
| |
|
|
|
|
|
|
|
| |
Seems to have been left out by 874f5c1f463cad61f49e0ff7007852a73fd93e7c
Pick-to: 6.7
Fixes: QTBUG-123478
Change-Id: Ic028c3786203cbc1c3d7316c1ae22c12a928b170
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
| |
|
|
|
|
|
|
|
|
|
| |
We must not try to escape a driver string, the user has to make sure
that everything is correctly escaped when passing a complete driver
string. This fixes a regression from QTBUG-122642.
Pick-to: 6.7
Fixes: QTBUG-123444
Change-Id: I43316c7a09060f5c8117fdc3c464d239e37d9cdf
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
... but use QStringView instead in setConnectionOptions() and the
dependent functions.
Also remove the (undocumented) ability to pass the connection options in
non-uppercase - this was never supported and all other plugins don't
support this either.
[ChangeLog][SQL][ODBC] All options must now be upper-cased as documented. Lower-cased options are no longer supported.
Change-Id: I822db1ddf205c22fe939299c4ab741bbe9b56d65
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
| |
Use the categorized logger qt.sql.sqlite
Change-Id: I70880fca579df56500ddc94a72bc6c616c475e67
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
| |
Use the categorized logger qt.sql.mysql
Change-Id: I7e6529025dceb81c47571c65b7aea9bd274814e2
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
| |
Use the categorized logger qt.sql.odbc
Change-Id: I1411e80fa33582857bafdf77baee75b293df56af
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
Change the invalid static_cast<std::int16_t>(i)+1
to the correct static_cast<std::int16_t>(i+1).
Change-Id: I5d3e17d29deb2a70fa0d7d7838531a3dc80b4e45
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
|
| |
|
|
|
|
|
|
|
|
|
| |
Calling data() for parameters of the type bigint
failed in combination with stored procedures with
output parameters. Cast the result to qlonglong to
fix it.
Pick-to: 6.7 6.6
Change-Id: I84ef04ed26821b92ef7c5bcdf12b778e91450e0b
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These options are declared with TYPE enum and a MAPPING that's supposed
to control the feature 'system-zlib' or 'system-sqlite'. Since only
inputs of type boolean control features now, we need to somehow declare
that this non-boolean input controls a feature.
We do this by adding the keyword CONTROLS_FEATURE to
qt_commandline_option. For example,
qt_commandline_option(zlib
CONTROLS_FEATURE
TYPE enum
NAME system-zlib
MAPPING system yes qt no
)
declares
- commandline option "zlib" sets the input "system-zlib",
because of the "NAME system-zlib" argument
- accepted input values are "system" and "qt", because
we have "TYPE enum" and the odd values of MAPPING
- those values are translated to yes/no, because of the
even values of MAPPING
- CONTROLS_FEATURE forces the translated input's type
to boolean, and with that it will set the corresponding
feature 'system-zlib'
Luckily, only qtbase has command line options with MAPPING declared.
Change-Id: I82d06cec43ece3b002c8f5dd414c68dc730909af
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
|
| |
|
|
|
|
|
| |
Use the categorized logger qt.sql.postgresql
Change-Id: I480346cadb879c22874f0af92d6e05d513f25b48
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The postgresql server by default returns the datetime in it's local
timezone. This works as long as this is the same as on the client. If
they are different, the parsing is going wrong.. Therefore let the
server return the datetime in UTC. Also do not convert the datetime into
local time to be in sync with the MySQL plugin.
[ChangeLog][SQL][PostgreSQL] Fixed a bug where a wrong QDateTime might
be returned when the PostgreSQL server and the Qt client had different
time zones configured.
Fixes: QTBUG-115960
Change-Id: I1a6dda69359a34b99ef399b2a54f35c8ba041326
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
|
|
|
|
|
|
|
| |
Creating a QString from a QDate/QTime works even when
QT_CONFIG(datestring) is not defined, so no need to ifdef it out.
Pick-to: 6.7
Change-Id: Ib3594036f309393b612d3fbf21f51be9c36a9391
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The MYSQL_TIME structure doesn't support per-datum timezone and in any
case the server would not store it: the TIMESTAMP type is always stored
in UTC. So instead let's configure the session time zone to UTC and use
QDateTime to convert to/from it.
Fixes https://bugs.kde.org/show_bug.cgi?id=483060
[ChangeLog][SQL][MySQL] Fixed a bug in passing QDateTime to be passed as
local time to the server, regardless of the QDateTime's time zone
setting. This would cause certain timestamps to be rejected by the
server, such as a UTC time stamp whose time numerically matched the
local timezone's spring forward gap in the transition into Daylight
Savings Time.
Change-Id: I6818d78a57394e37857bfffd17bbce4ae43e823c
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
It was the only place that called it. Makes the code slightly uglier,
but removes a function that returned a raw pointer. More importantly, it
gets the actual type from QVariant, without relying on it internally
converting from QDateTime to QDate and QTime, or failing to do so in
some cases. This is going to be needed for the next commit.
Pick-to: 6.5 6.6 6.7
Change-Id: I6818d78a57394e37857bfffd17bbcd3f5057eadc
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
| |
|
|
|
|
|
|
|
| |
These functions set/get the db-specific internal sql type but it's not
used in any of the sql plugins since ages. Any external plugin using this for some reason must be ported away until Qt7.
Change-Id: Ifb33e9d3be0b80fb4d0979d31436e89ea6a8208b
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
| |
|
|
|
|
|
|
|
|
| |
Retrieve the default value (if set) of a column during
QSqlDatabase::record() but not for QSqlQuery::record() as it's done for
the other drivers which support retrieving the default column value.
Fixes: QTBUG-122723
Change-Id: I92e052bfa6d88e019c0151fbcbc1483a65770c55
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
| |
Replace all qWarning() with qSqlWarning() to be able to get additional
error/warning output from the handles.
Change-Id: Ieaa947fe06216b3d20b20c509080fc409803683b
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
| |
It shows for example when starting assistant.
Amends 3379fd2322d112af4ef7ce75aafe18c27746acae.
Pick-to: 6.7
Change-Id: I85196c62ff9d9caaa46a5279c3b965dc28266ba8
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
|
| |
|
|
|
|
|
|
| |
This value does not change over time so no need to retrieve it from the
driver for every call. As a drive-by change the enum to an enum class.
Change-Id: I25292d724f5173fef7054bb5e7e82e82992e41c6
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
Values in connection strings must be escaped when they
- contain a ; -> escape with "
- start with ' -> escape with "
- start with " -> escape with '
Fixes: QTBUG-122642
Pick-to: 6.7
Change-Id: I1df638194067af5df94a34009e1547886fdf928c
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
| |
|
|
|
|
|
|
| |
Use SQL_SUCCEEDED(r) instead checking for SQL_SUCCESS and
SQL_SUCCESS_WITH_INFO separately on every return.
Change-Id: Ic5c0e7d13b4ce117a23bbee9311980146b13ba4d
Reviewed-by: Axel Spoerl <axel.spoerl@qt.io>
|