Ver Mensaje Individual
  #3 (permalink)  
Antiguo 14/04/2011, 11:16
mogurbon
 
Fecha de Ingreso: enero-2011
Ubicación: DF
Mensajes: 898
Antigüedad: 13 años, 3 meses
Puntos: 155
Respuesta: problema con: Undefined offset mysql_fetch_array

a ver pruebale cambiando

Código PHP:
<?
$i
=0
    while (
$i $cantidad_rango){ 
         
        
$num_pedimento $array1[$i]; 
         
        
$partidas_pedimento mysql_query("SELECT DESCRIPCION FROM partidas WHERE NUM_PEDIMENTO = '$num_pedimento' LIMIT $i, 1"); 
        if (!
$partidas_pedimento) {die("Error en variable partidas_pedimento: " mysql_error());}; 
         
        
$array_partidas_pedimento mysql_fetch_array($partidas_pedimento); 
        echo 
$array_partidas_pedimento['DESCRIPCION']."<br />"
        
$i++; 
         
    };
?>
por esto

Código PHP:
 $i=0;
    while (
$row mysql_fetch_array($rango_fechas_pedimentosMYSQL_ASSOC)) {
    
        
$num_pedimento $row["NUM_PEDIMENTO"]; 
         
        
$partidas_pedimento mysql_query("SELECT DESCRIPCION FROM partidas WHERE NUM_PEDIMENTO = '$num_pedimento' LIMIT $i, 1"); 
        if (!
$partidas_pedimento) {die("Error en variable partidas_pedimento: " mysql_error());}; 
         
        
$array_partidas_pedimento mysql_fetch_array($partidas_pedimento); 
        echo 
$array_partidas_pedimento['DESCRIPCION']."<br />"
        
$i++; 
        
    }