Ver Mensaje Individual
  #1 (permalink)  
Antiguo 16/11/2009, 11:45
mhax
 
Fecha de Ingreso: agosto-2009
Ubicación: Cartagena, Colombia
Mensajes: 516
Antigüedad: 14 años, 8 meses
Puntos: 13
Pregunta Problema con max()

Saludos::::::::::::::

tengo la siguiente tabla

table1
____________
id
-------------------
1
2
4
6
--------------------

Cuando realizo esta consulta "select max(id) from table1"
me muestra 1.
la consulta la hago sobre php

codigo:
Código PHP:
       $bd =  new BDOracle();
        
$query_max "select MAX() from Documento";
        
$stmt=ociparse($bd->Conectar(),$query_max);
        
$max ociexecute($stmt);
        echo 
$max
por que $max toma el valor de 1??