Ver Mensaje Individual
  #2 (permalink)  
Antiguo 11/03/2003, 12:30
Avatar de Cain
Cain
 
Fecha de Ingreso: enero-2002
Ubicación: Catalunya
Mensajes: 6.459
Antigüedad: 22 años, 3 meses
Puntos: 17
Si tienes que hacer múltiples inserts. Acuérdate de hacer un LOCK tables antes de empezar el bucle y un UNLOCK al final.

Código PHP:
<?
$bloquea 
mysql_query("LOCK TABLES tabla WRITE");
for (
$i=0$i<$total$i){
$entra mysql_query("INSERT INTO tabla (campos) VALUES ($valores)");
}
$bloquea mysql_query("UNLOCK TABLES");
?>
__________________
M a l d i t o F r i k i