# HG changeset patch # User Alain Mazy # Date 1747901634 -7200 # Node ID 3ef7ca1147909aec89887f69bf656ab70d43e755 # Parent 48460f6536289d4d6dd423d8a5cb6bcc0bd0e643 fixes diff -r 48460f653628 -r 3ef7ca114790 Framework/Plugins/IndexBackend.cpp --- a/Framework/Plugins/IndexBackend.cpp Wed May 21 23:42:55 2025 +0200 +++ b/Framework/Plugins/IndexBackend.cpp Thu May 22 10:13:54 2025 +0200 @@ -4497,7 +4497,7 @@ { DatabaseManager::CachedStatement statement( STATEMENT_FROM_HERE, manager, - "INSERT INTO Queues VALUES(${queueId}, ${value})"); + "INSERT INTO Queues VALUES(${AUTOINCREMENT} ${queueId}, ${value})"); Dictionary args; @@ -4525,13 +4525,13 @@ { statement.reset(new DatabaseManager::CachedStatement( STATEMENT_FROM_HERE, manager, - "SELECT id, value FROM Queues WHERE storeId= " + queueIdParameter + " ORDER BY id ASC " + formatter.FormatLimits(0, 1))); + "SELECT id, value FROM Queues WHERE queueId= " + queueIdParameter + " ORDER BY id ASC " + formatter.FormatLimits(0, 1))); } else { statement.reset(new DatabaseManager::CachedStatement( STATEMENT_FROM_HERE, manager, - "SELECT id, value FROM Queues WHERE storeId= " + queueIdParameter + " ORDER BY id DESC " + formatter.FormatLimits(0, 1))); + "SELECT id, value FROM Queues WHERE queueId= " + queueIdParameter + " ORDER BY id DESC " + formatter.FormatLimits(0, 1))); } statement->Execute(formatter.GetDictionary()); diff -r 48460f653628 -r 3ef7ca114790 PostgreSQL/Plugins/SQL/PrepareIndex.sql --- a/PostgreSQL/Plugins/SQL/PrepareIndex.sql Wed May 21 23:42:55 2025 +0200 +++ b/PostgreSQL/Plugins/SQL/PrepareIndex.sql Thu May 22 10:13:54 2025 +0200 @@ -1,4 +1,4 @@ --- This SQL file creates a DB in Rev2 directly +-- This SQL file creates a DB in Rev5 directly -- It is also run after upgrade scripts to create new tables and or create/replace triggers and functions. -- This script is self contained, it contains everything that needs to be run to create an Orthanc DB. -- Note to developers: @@ -721,7 +721,7 @@ EXECUTE PROCEDURE UpdateChildCount(); --- new in 1.12.99 +-- new in 1.12.99 (rev 5 ?) CREATE TABLE KeyValueStores( storeId TEXT NOT NULL,