Microsoft
Software
Hardware
Network
Question : SQL Substr Order
I have a select statement that uses substr
select distinct substr(value, 1, 1) from table
This query returns letters (i.,e, H, O, B, D).
I need those letters to be sorted alphabetically (B, D, H, O).
How can I do this with this query. I tried adding "sort by value" and "order by value". I got an SQL error for both.
Using Oracle 10g.
Answer : SQL Substr Order
select distinct substr(value, 1, 1) from table
order by 1;
or give it an alias
select distinct substr(value, 1, 1) letter from table
order by letter;
Random Solutions
Access Report Using '=Format$' asks for Parameter when Opened
mcafee EPO script to remove agent and virusscan
How to demote windows 2003 domain controller
Is it possible to apply style, such as bold or color, to a single line in TMemo1 control?
intuitive understanding of the area under the curve - again
Wireless LAN , Larger Scale
Mounting a Windows XP share under linux
Insert into MySQL Table from MSSQL Insert Trigger
Event code: 3005 - An unhandled exception has occurred with custom ASP.Net app
Shell Script