Re: [MYSQL] Commands out of sync; You can't run this command now
| From: | Àngel Fenoy | Date: | Sun, 06 May 2001 21:53:33 +0000 |
| Subject: | Re: [MYSQL] Commands out of sync; You can't run this command now | ||
| References: | 1 | Groups: | php.general.es |
| Request: | Send a blank email to general-es+get-9713@lists.php.net to get a copy of this message | ||
Diumenge 06 Maig 2001 23:25, maseducativa.com dixit:
> Hola:
>
> ¿Aguien sabe a qué se debe este error que aparece de vez en cuando, cuando
> se intenta conectar a un base de datos mySQL desde un script en PHP 4.0.5?
>
> El error es "Commands out of sync; You can't run this command now"
>
> Un saludo
> Manuel P.
Del manual de mysql (http://www.mysql.com/doc/C/o/Commands_out_of_sync.html):
------------------------------
21.4.12 Commands out of sync Error in Client
If you get Commands out of sync; You can't run this command now in your
client code, you are calling client functions in the wrong order!
This can happen, for example, if you are using mysql_use_result() and try to
execute a new query before you have called
mysql_free_result(). It can also happen if you try to execute two queries
that return data without a mysql_use_result() or
mysql_store_result() in between.
-------------------------------
¿Te está ocurriendo esto después de cambiar a php 4.0.5? ¿Con el mismo código
que sí funcionaba en php 4.0.4?
Si es así, puede deberse a un error en php 4.0.5, pero lo he estado buscando
en http://bugs.php.net y no lo veo.
En fin, no sé qué pueda ser, pero ya tienes un poco más de información.
Saludos
Àngel