diff --git a/htdocs/install/etape2.php b/htdocs/install/etape2.php
index 865989f9e61..8f81e55614c 100644
--- a/htdocs/install/etape2.php
+++ b/htdocs/install/etape2.php
@@ -188,6 +188,12 @@ if ($action == "set")
{
$buffer=preg_replace('/type=innodb/i','ENGINE=innodb',$buffer);
}
+
+ // Replace the prefix tables
+ if ($dolibarr_main_db_prefix != 'llx_')
+ {
+ $buffer=preg_replace('/llx_/i',$dolibarr_main_db_prefix,$buffer);
+ }
//print "
| Creation de la table $name/td>";
$requestnb++;
@@ -330,6 +336,12 @@ if ($action == "set")
$buffer=trim($req);
if ($buffer)
{
+ // Replace the prefix tables
+ if ($dolibarr_main_db_prefix != 'llx_')
+ {
+ $buffer=preg_replace('/llx_/i',$dolibarr_main_db_prefix,$buffer);
+ }
+
//print " |
| Creation des cles et index de la table $name: '$buffer' | ";
$requestnb++;
if ($conf->file->character_set_client == "UTF-8")
@@ -538,6 +550,12 @@ if ($action == "set")
// We loop on each requests
foreach($arrayofrequests as $buffer)
{
+ // Replace the prefix tables
+ if ($dolibarr_main_db_prefix != 'llx_')
+ {
+ $buffer=preg_replace('/llx_/i',$dolibarr_main_db_prefix,$buffer);
+ }
+
//dolibarr_install_syslog("Request: ".$buffer,LOG_DEBUG);
$resql=$db->query($buffer);
if ($resql)