Ver Mensaje Individual
  #4 (permalink)  
Antiguo 19/07/2006, 14:30
Avatar de PequeñoMauro
PequeñoMauro
 
Fecha de Ingreso: abril-2006
Ubicación: Lima - Perú
Mensajes: 600
Antigüedad: 18 años, 1 mes
Puntos: 3
Puedes hacerlo de dos formas:
Cita:
select distinct inicial from
(select distinct nombre,substr(nom,1,1) inicial from tu_tabla
order by nombre) a
o

Código:
SELECT DISTINCT SUBSTR(NOMBRE,1,1) AS inicial FROM 
DE_ENTIDAD 
ORDER BY inicial
El error es que como el campo nombre no esta en el select sin una función que le afecte por eso no se puede ordenar por tal.
Saludos
__________________
"Nada en mis manos traigo tan solo a tu cruz me aferro....."