From de293c4ef2ec2aa3a5c60eace86d448437facaf4 Mon Sep 17 00:00:00 2001 From: Florian Mortgat Date: Tue, 30 Jul 2019 14:09:03 +0200 Subject: [PATCH] FIX issue #9300: install error with PostgreSQL when using custom table prefix --- htdocs/install/step2.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/htdocs/install/step2.php b/htdocs/install/step2.php index 30b3ff7d64f..a53e5f07ee7 100644 --- a/htdocs/install/step2.php +++ b/htdocs/install/step2.php @@ -451,6 +451,11 @@ if ($action == "set") $buffer=trim($buffer); if ($buffer) { + // Replace the prefix in table names + if ($dolibarr_main_db_prefix != 'llx_') + { + $buffer=preg_replace('/llx_/i',$dolibarr_main_db_prefix,$buffer); + } dolibarr_install_syslog("step2: request: " . $buffer); print "\n"; $resql=$db->query($buffer,0,'dml');