Foros del Web

Foros del Web (http://www.forosdelweb.com/)
-   PHP (http://www.forosdelweb.com/f18/)
-   -   Warning: mysql_fetch_array(): supplied argument is not a valid MySQL (http://www.forosdelweb.com/f18/warning-mysql_fetch_array-supplied-argument-not-valid-mysql-579882/)

eddyri21 25/04/2008 07:21

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL
 
que es lo que faltaria.. porq no tengo idea

<?php
$int_periodo=1;
$enlace=mysql_connect("localhost:3306","root","");
mysql_select_db("db_evaluacion");
$str_sql_bus_pre = "CALL RHABuscar_Preguntas(".$int_periodo.",1,'A')";
$resultado=mysql_query($str_sql_bus_pre,$enlace);
#echo $str_sql_bus_pre;
$int_preguntas_a=0;
while($preguntas = mysql_fetch_array($resultado) ) {

echo "
<tr>
<td colspan='2' rowspan='13' align='center' valign='top'></td>
<td height='21'><div align='center'><strong>".$preguntas['indice']."</strong></div></td>
<td width='368'>".$preguntas['preguntas']."</td>
<td width='14'>&nbsp;</td>
<td colspan='2' valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='1'></td>
<td valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='2'></td>
<td valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='3'></td>
<td valign='middle' align='center'><input name='pregunta_a[".$int_preguntas_a."]' type='radio' value='4'></td>
<td colspan='2' valign='middle' align='center'><input name='pregunta_b[".$int_preguntas_a."]' type='radio' value='5'></td><input type='hidden' name='cod_pre_a[".$int_preguntas_a."]' value='".$preguntas['codigo']."' >
</tr>";
$int_preguntas_b++;
}
?>


GRACIAS!

jago86 25/04/2008 08:03

Re: Warning: mysql_fetch_array(): supplied argument is not a valid MySQL
 
Pon la linea de la consulta asi para ver si te devuelve algun error en la misma,
$resultado=mysql_query($str_sql_bus_pre,$enlace) or die (mysql_error());


La zona horaria es GMT -6. Ahora son las 08:54.

Desarrollado por vBulletin® Versión 3.8.7
Derechos de Autor ©2000 - 2026, Jelsoft Enterprises Ltd.