Commit 9274943c authored by Antony Le Courtes's avatar Antony Le Courtes
Browse files

Correction sur update-employeur selon les versions d'ORACLE.

parent e3da5abd
Loading
Loading
Loading
Loading
+3 −2
Changes for admin/actions/update-employeur.php: 3 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -8,7 +8,7 @@ $oseSource = $oa->getSourceOseId();
$oseId     = $oa->getOseAppliId();
$c->println("Mise à jour de la table employeur");

ini_set('memory_limit', '6144M');
ini_set('memory_limit', '8192M');
$importDirectory = $osedir . 'cache/employeurs/';
$importArchive   = 'employeurs.tar.gz';
$importFilePath  = $importDirectory . $importArchive;
@@ -33,7 +33,8 @@ if (count($listFiles) > 0) {
exec('cd ' . $importDirectory . ' && tar -xvf ' . $importFilePath);
//Verification si des SIRET sont déjà chargé en base
$bdd = $oa->getBdd();
$haveAlreadySiret     = $bdd->select("SELECT siret FROM employeur e WHERE siret IS NOT null FETCH FIRST 5 ROWS ONLY", [], ['fetch' => $bdd::FETCH_ONE]);
//$haveAlreadySiret     = $bdd->select("SELECT siret FROM employeur e WHERE siret IS NOT null FETCH FIRST 5 ROWS ONLY", [], ['fetch' => $bdd::FETCH_ONE]);
$haveAlreadySiret     = $bdd->select("select siret from (select siret, rownum as rn FROM employeur e WHERE siret IS NOT NULL) e where e.rn < 10", [], ['fetch' => $bdd::FETCH_ONE]);
$haveAlreadyEmployeur = $bdd->select("SELECT * FROM employeur e");