Fixing stacked writing for PgSQL

This commit is contained in:
Miroslav Štampar 2026-06-04 20:39:59 +02:00
parent 6d1382f448
commit 46ba1d1bf1
3 changed files with 4 additions and 4 deletions

View file

@ -65,7 +65,7 @@ class Filesystem(GenericFilesystem):
for sqlQuery in sqlQueries:
inject.goStacked(sqlQuery)
inject.goStacked("INSERT INTO pg_largeobject VALUES (%d, %d, DECODE((SELECT %s FROM %s), 'base64'))" % (self.oid, self.page, self.tblField, self.fileTblName))
inject.goStacked("INSERT INTO pg_largeobject VALUES (%d, %d, DECODE((SELECT ARRAY_TO_STRING(ARRAY_AGG(%s), '') FROM %s), 'base64'))" % (self.oid, self.page, self.tblField, self.fileTblName))
inject.goStacked("DELETE FROM %s" % self.fileTblName)
self.page += 1