SQL tests: Fix for PostgreSQL 12 and above
The 'WITH OIDS' was deprecated some time ago and removed with PostgreSQL 12 so we have to adjust our test table creations. Don't know why it was used in the first place at all. Change-Id: I6e18ac01e64368b1dd64e02bcb75fa70e05467a3 Reviewed-by: Dimitrios Apostolou <jimis@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 87662bcf107e65c04f933f212f4c8cad6692f948) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
da6e6861c1
commit
2779ba3276
@ -404,7 +404,7 @@ void tst_QSqlQuery::createTestTables(QSqlDatabase db)
|
||||
if (dbType == QSqlDriver::PostgreSQL) {
|
||||
QVERIFY_SQL(q, exec(QLatin1String(
|
||||
"create table %1 (id serial NOT NULL, t_varchar varchar(20), "
|
||||
"t_char char(20), primary key(id)) WITH OIDS").arg(qtest)));
|
||||
"t_char char(20), primary key(id))").arg(qtest)));
|
||||
} else {
|
||||
QVERIFY_SQL(q, exec(QLatin1String(
|
||||
"create table %1 (id int %2 NOT NULL, t_varchar varchar(20), "
|
||||
|
Loading…
x
Reference in New Issue
Block a user