Change default prefix if needed
This commit is contained in:
parent
89b521ccfe
commit
c64f16da1c
@ -189,6 +189,12 @@ if ($action == "set")
|
|||||||
$buffer=preg_replace('/type=innodb/i','ENGINE=innodb',$buffer);
|
$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 "<tr><td>Creation de la table $name/td>";
|
//print "<tr><td>Creation de la table $name/td>";
|
||||||
$requestnb++;
|
$requestnb++;
|
||||||
if ($conf->file->character_set_client == "UTF-8")
|
if ($conf->file->character_set_client == "UTF-8")
|
||||||
@ -330,6 +336,12 @@ if ($action == "set")
|
|||||||
$buffer=trim($req);
|
$buffer=trim($req);
|
||||||
if ($buffer)
|
if ($buffer)
|
||||||
{
|
{
|
||||||
|
// Replace the prefix tables
|
||||||
|
if ($dolibarr_main_db_prefix != 'llx_')
|
||||||
|
{
|
||||||
|
$buffer=preg_replace('/llx_/i',$dolibarr_main_db_prefix,$buffer);
|
||||||
|
}
|
||||||
|
|
||||||
//print "<tr><td>Creation des cles et index de la table $name: '$buffer'</td>";
|
//print "<tr><td>Creation des cles et index de la table $name: '$buffer'</td>";
|
||||||
$requestnb++;
|
$requestnb++;
|
||||||
if ($conf->file->character_set_client == "UTF-8")
|
if ($conf->file->character_set_client == "UTF-8")
|
||||||
@ -538,6 +550,12 @@ if ($action == "set")
|
|||||||
// We loop on each requests
|
// We loop on each requests
|
||||||
foreach($arrayofrequests as $buffer)
|
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);
|
//dolibarr_install_syslog("Request: ".$buffer,LOG_DEBUG);
|
||||||
$resql=$db->query($buffer);
|
$resql=$db->query($buffer);
|
||||||
if ($resql)
|
if ($resql)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user