Correct sql request

This commit is contained in:
Michael RICOIS 2013-01-29 19:20:55 +00:00
parent 4fdfe03389
commit 2a991e8952

View File

@ -103,7 +103,7 @@ class Entreprise extends WsScore
$identite->Privileges = true;
} else {
$iDb = new WDB('sdv1');
$sql = "SELECT count(*) AS nbPriv FROM ge_cs2 WHERE cs = 'P' AND dateFin >= NOW() AND dateSuppr=0;";
$sql = "SELECT count(*) AS nbPriv FROM ge_cs2 WHERE cs = 'P' AND dateFin >= NOW() AND dateSuppr=0 AND siren=$siren;";
$ret = $iDb->query($sql);
if ($ret['nbPriv']>0) {
$identite->Privileges = true;