[GENERAL] Natural ordering in postgresql? Does it exist?
Hi all, I have a field that I'll be ordering and I noticed that ordering is done logically and would confuse my users here (1,12,16,4,8, etc). I'm writing an application in PHP that connects to Postgres and while I know that PHP has some powerful natural ordering functions it would be much easier if I could just use something from postgres directly. Does there exist any way to order naturally? Thanks, Clark Endrizzi _ Is your PC infected? Get a FREE online computer virus scan from McAfee® Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 ---(end of broadcast)--- TIP 7: don't forget to increase your free space map settings
[GENERAL] To_char statement problems
I just sent this twice before with the wrong email address so it didn't go through, that is why I am sending this so that it will get through. I hope this isn't causing issues. Hi guys. I certainly hope this is the correct place to email this. I'm having an issue that I have really tried to solve but can't. I'm using RHEL's postgresql 7.3.4 and everything works great except my to_char() statements. The most common conversion string I use is 'MM/DD/ HH:MM AM' which works except the minutes are never correct, they always end with ":04". So if I submitted it at 10:23 AM it will say 10:04 after conversion. I know Redhat doesn't have the newest version but I can't believe that they would have such a big problem. Is this just a problem in this version? Is my syntax incorrect? Thanks! -- Clark Endrizzi NAI Utah Commercial Real Estate 801-578-5522