Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: MySQL Alphabetical order with DBI

by UnderMine (Friar)
on Nov 15, 2002 at 14:05 UTC ( [id://213156]=note: print w/replies, xml ) Need Help??


in reply to MySQL Alphabetical order with DBI

Do it in the database....
SELECT Name, RIGHT(Name,LENGTH(Name)-LOCATE(' ',Name)) as sortorder FROM Addresses ORDER BY RIGHT(Name,LENGTH(Name)-LOCATE(' ',Name))
Better still store your data in a more usable format ;) Thanks UnderMine

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://213156]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (None)
    As of 2024-04-25 00:23 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      No recent polls found