Mercurial > hg > orthanc-databases
changeset 77:a2134531473c db-changes
avoid warnings "An active PostgreSQL transaction was dismissed"
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Sun, 06 Jan 2019 12:35:29 +0100 |
parents | a1c6238b26f8 |
children | 2ee166f77501 |
files | PostgreSQL/Plugins/PostgreSQLIndex.cpp |
diffstat | 1 files changed, 8 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/PostgreSQL/Plugins/PostgreSQLIndex.cpp Sat Jan 05 15:51:25 2019 +0100 +++ b/PostgreSQL/Plugins/PostgreSQLIndex.cpp Sun Jan 06 12:35:29 2019 +0100 @@ -164,6 +164,10 @@ << "PostgreSQL server, e.g. on Debian: sudo apt install postgresql-contrib"; } } + else + { + t.Commit(); + } } { @@ -182,9 +186,9 @@ db->Execute(query); SetGlobalIntegerProperty(*db, t, Orthanc::GlobalProperty_HasCreateInstance, 1); + } - t.Commit(); - } + t.Commit(); } { @@ -203,9 +207,9 @@ db->Execute(query); SetGlobalIntegerProperty(*db, t, Orthanc::GlobalProperty_GetTotalSizeIsFast, 1); + } - t.Commit(); - } + t.Commit(); } return db.release();