Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to Sort by the length of the returned value from a query.

Stanley Lee-OracleDec 3 2013 — edited Dec 3 2013

Hi,

I was wondering if it is possible to sort by the length of the returned value from a query?

For example if I want to get a list of people with the name 'Samuel', I would like to short by how short the length of the whole name is.

Sort by length of the name in SQL

--------------------------------------------------

Samuel Syda

Samuel Indranaka

Samuel Johnsons

Samuel Longhenderson

Thank you.

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 31 2013
Added on Dec 3 2013
2 comments
1,986 views