
17/08/2009, 20:16
|
 | $this->role('moderador'); | | Fecha de Ingreso: mayo-2006 Ubicación: /home/ams/
Mensajes: 38.567
Antigüedad: 18 años, 8 meses Puntos: 2135 | |
Respuesta: no tengo ni idea de como hacer esto, quien me ayuda? Prueba tu query así:
Código SQL:
Ver originalSELECT producto,SUM(cantidad)AS cantidad_total FROM tablas WHERE fecha>='$fecha' GROUP BY producto ORDER BY cantidad_total DESC LIMIT 7
Saludos. |