From 23165ca418a6f5c21ae283fb8ce157d84bc0fa40 Mon Sep 17 00:00:00 2001 From: John Rouillard Date: Mon, 20 Jan 2025 16:32:39 -0500 Subject: [PATCH] backout bbc99def147a. All the other backends were programmed to accomodate the skip one nature of postgres sequences --- CHANGES.txt | 4 ---- roundup/backends/back_postgresql.py | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index e235cedd..9d986705 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -81,10 +81,6 @@ Fixed: date input. Also add double-click and exit keyboard handlers to allow copy/paste/editing the text version of the date. (John Rouillard) -- issue2550815 - roundup-admin import for postgres causes id to - be skipped. Fixed code so that the id used to set the sequence - will be returned and not skipped. (Tom Ekberg diagnosed and - supplied the fix. John Rouillard committed) - issue1895197 - translated help texts in admin.py not displayed correctly. (Initial patch tobias-herp, John Rouillard) - issue2551238 - roundup-server should exit with error if -d diff --git a/roundup/backends/back_postgresql.py b/roundup/backends/back_postgresql.py index 419bdc1e..4aa71edf 100644 --- a/roundup/backends/back_postgresql.py +++ b/roundup/backends/back_postgresql.py @@ -548,7 +548,7 @@ def newid(self, classname): return str(self.cursor.fetchone()[0]) def setid(self, classname, setid): - sql = "select setval('_%s_ids', %s, false) from dual" % (classname, + sql = "select setval('_%s_ids', %s) from dual" % (classname, int(setid)) self.sql(sql)