ID: 22636
User updated by: real_mctl at yahoo dot fr
Reported By: real_mctl at yahoo dot fr
Status: Bogus
Bug Type: MySQL related
Operating System: Linux Red Hat 7.2
PHP Version: 4.3.1
New Comment:
a
Previous Comments:
------------------------------------------------------------------------
[2003-03-12 02:49:25] real_mctl at yahoo dot fr
<?
function fSelectionnerNiveauSuivi(&$tabNiveauSuivi)
{
$succes=false;
if ( ($idLienCnx=fConnecterBase(CONFIG_SUJET)) != false) //
fConnecterBase() works properly, parses a constant who contains
identifiers for the connection to the database
{
if (($resultat = fSelectNiveauSuivi($idLienCnx))!= false)
{
$succes=true;
while ($ligne=mysql_fetch_object($resultat))
{
$tabNiveauSuivi['idNiveauSuivi'][]=$ligne->idNiveauSuivi;
$tabNiveauSuivi['nom'][]=$ligne->nom;
}
$succes = fLiberer($resultat,$succes); // fLiberer()
free the
memory (works properly)
}
$succes=fDeconnecterBase($idLienCnx,$succes); //
fDeconnecterBase()
close the connection with the base
}
return $succes ;
}
function fSelectNiveauSuivi($idLienCnx)
{
$requete="SELECT * FROM NiveauSuivi ORDER BY nom ";
$resultat=fEmettreRequete($requete,$idLienCnx) ;
return $resultat ;
}
function fEmettreRequete($requete,$idLienCnx)
{
// Emission de la requ�te
$resultat = @mysql_query($requete,$idLienCnx);
if ($resultat==false)
{
// Requ�te en erreur
fEnregistrerErreur(mysql_errno(), mysql_error() . " Requete:" .
$requete) ; // fEnregistrerErreur() mails the webmaster that an error
occured when quering the database
}
// Retour
return $resultat ;
}
$succes = fSelectionnerNiveauSuivi(&$tabNiveauSuivi) ;
?>
OK !
The script works perfect with PHP 4.1.2 but with 4.3.1, it does not
work
One other detail : the functions listed above are in different include
files and the include instruction is always called when necessary.
After all, if I reload the page with the script, i have no problem
Is this bogus again ??
Thanks
------------------------------------------------------------------------
[2003-03-11 20:39:34] [EMAIL PROTECTED]
Can't reproduce. You're doing something wrong obviously.
------------------------------------------------------------------------
[2003-03-11 14:40:06] real_mctl at yahoo dot fr
no need to copy the entire code (huge app).
the code before and after mysql_query is correct.
------------------------------------------------------------------------
[2003-03-11 11:20:17] [EMAIL PROTECTED]
And add a _FULL_ but short example script here, not just 2 lines from
one..
------------------------------------------------------------------------
[2003-03-11 11:19:37] [EMAIL PROTECTED]
huh? What if you remove that @ from the mysql_query() call?
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/22636
--
Edit this bug report at http://bugs.php.net/?id=22636&edit=1