From ff6b62adf3a2903fcec19327986b716a385f159a Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Fri, 24 Jul 2015 15:15:41 +0200 Subject: [PATCH] Important additional patch for #1170 (for PgSQL >= 9.0) --- plugins/dbms/postgresql/filesystem.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/dbms/postgresql/filesystem.py b/plugins/dbms/postgresql/filesystem.py index d3bc2516e..72cf7c75f 100644 --- a/plugins/dbms/postgresql/filesystem.py +++ b/plugins/dbms/postgresql/filesystem.py @@ -53,6 +53,8 @@ class Filesystem(GenericFilesystem): # http://www.postgresql.org/docs/8.3/interactive/lo-funcs.html inject.goStacked("SELECT lo_unlink(%d)" % self.oid) + inject.goStacked("SELECT lo_create(%d)" % self.oid) + inject.goStacked("DELETE FROM pg_largeobject WHERE loid=%d" % self.oid) for offset in xrange(0, wFileSize, LOBLKSIZE): fcEncodedList = self.fileContentEncode(content[offset:offset + LOBLKSIZE], "base64", False)