Error mysql
| From: | Amador Cubino [Necostek.com] | Date: | Fri, 29 Aug 2003 23:07:21 +0000 |
| Subject: | Error mysql | ||
| Groups: | php.general.es | ||
| Request: | Send a blank email to general-es+get-39967@lists.php.net to get a copy of this message | ||
Hola, el siguiente codigo
$fecha1 = "25-08-2003";
$fecha2 = "30-08-2003";
$resultado= mysql_query("select Usuarios.url, avg(publi_stats_real.visitas) from Usuarios,
publi_stats_real where Usuarios.id = publi_stats_real.idweb and publi_stats_real.fecha >
'$fecha1' and publi_stats_real.fecha < '$fecha2'",$conexion);
while ($registro = mysql_fetch_array($resultado)){
$user= $registro['url'];
$visitas = $registro['visitas'];
echo " $user - $visitas visitas <br>";
}
me da este error
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in
/home/cubino/public_html/hispanel/panelad-estadisticas.php on line 22
Yo lo que intento es hacer una media las visitas de los ultimos 5 dias por web.
A ver si alguien puede ayudarme
*************************************************
D. Amador Cubino
Presidente de Necostek y asociadas
*************************************************
http://www.NECOSTEK.com - Imagen Comercial
http://www.HISPADOMINIO.com - Hosting Gratis
http://www.DISENTWEB.COM - Hosting y Diseño web
*************************************************