FireFox! The PHP Forum Loans and Credit
Panama Web Design for Hire Free Insurance Quotes!
Web Hosting Advertise Here $10 a Month Designer Children
Never Pay Taxes Again HGH Domain name registration
Web Hosting and Dedicated Servers Insurance Affordable web-hosting


HomeWatched TopicsRegisterSearchDirectory
FAQMemberlistUsergroupsLog inStoresItemsBank
Google

Reply to topic Page 1 of 1
Order by mid part of field
Message  

Reply with quote
Post Order by mid part of field 
Hi guys

I have a MySQL database holding property data and each record has a reference number along the form of FLO123N, FLN123S, etc.

What I need to do is order these so that the numbers run 0-9 (ie. the part after FLO and FLN)... how can I order this data based only on the numers?

Thanks,


Dean

View user's profile Send private message

Reply with quote
Post  
I am not sure of an easy way to do that, but you could store the reference number as 2 fields in the database and then order them by the second field.  So when you store these numbers, store them with the first 3 characters in the first field and the rest in the second field.

View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:
Reply to topic Page 1 of 1
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
  



Google

FireFox! The PHP Forum Loans and Credit
Panama Web Design for Hire Free Insurance Quotes!
Web Hosting Advertise Here $10 a Month Designer Children
Never Pay Taxes Again HGH Domain name registration
Web Hosting and Dedicated Servers Insurance Affordable web-hosting


Web Design by PlatinumShore.com & Web Hosting by TradeWebHosting.com