Ver Mensaje Individual
  #1 (permalink)  
Antiguo 14/06/2011, 05:27
agugut
 
Fecha de Ingreso: agosto-2008
Mensajes: 88
Antigüedad: 15 años, 8 meses
Puntos: 0
Consulta Doctrine no funciona

Hola: tengo la siguiente consulta
Código:
$query = Doctrine_Query::create()
                        ->select('i.*')
                        ->from('Ingrediente i')
                        ->where('i.stockIngrediente<=?', 'i.stockMinimo')
->execute();
En teoria me tendria que devolver los ingredientes cuyo stockIngrediente <=stockMinimo, pero tengo almacenado valores que cumplen dicha condicion y no funciona. Solo funciona si pongo en stock ingrediente 0
Gracias