Ver Mensaje Individual
  #1 (permalink)  
Antiguo 04/12/2011, 01:03
Avatar de chechu_
chechu_
 
Fecha de Ingreso: mayo-2007
Mensajes: 282
Antigüedad: 17 años
Puntos: 0
Update cruzado

Hola, empiezo con codigo.
Código PHP:
mysql_query("UPDATE t1,t2 SET 
     t1.v1=t1.v1-1 
     WHERE 
     t2.v2 != ''
     "
); 
Me gustaria restar un valor en la tabla 1 por cada fila que tenga la tabla 2 ¿esto es posible con query?