From 2d14e53b4529bdb6fc497744d058c3e83f69079d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 30 Aug 2014 19:58:38 +0200 Subject: [PATCH] Fix: Pb with pgsql --- htdocs/core/db/pgsql.class.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/htdocs/core/db/pgsql.class.php b/htdocs/core/db/pgsql.class.php index 1200deee93e..0b0bc8c8a5c 100644 --- a/htdocs/core/db/pgsql.class.php +++ b/htdocs/core/db/pgsql.class.php @@ -298,6 +298,9 @@ class DoliDBPgsql extends DoliDB $line=str_replace(' LIKE \'',' ILIKE \'',$line); $line=str_replace(' LIKE BINARY \'',' LIKE \'',$line); + // Replace INSERT IGNORE into INSERT + $line=preg_replace('/^INSERT IGNORE/','INSERT',$line); + // Delete using criteria on other table must not declare twice the deleted table // DELETE FROM tabletodelete USING tabletodelete, othertable -> DELETE FROM tabletodelete USING othertable if (preg_match('/DELETE FROM ([a-z_]+) USING ([a-z_]+), ([a-z_]+)/i',$line,$reg))