MySQL Forums
Forum List  »  MySQL Query Browser

Can I format Query Output?
Posted by: Argenex Kronium
Date: May 05, 2006 08:03PM

For example, I have long numbers like the following number stored within the database (result of a calculation):


Is there a MySQL function or a PHP function that I can do to format the number so it displays as a percentage instead? I.E. the number itself is a percentage, but I would like to round the bastards off if you know what I mean.

Where the percentage of this number would be 188%

For the life of me I cannot seem to locate anything anywhere that lists functions of formating the output result of a query. I'm just displaying this stuff in html, nothing too exciting, and I only need the numbers rounded down. I suppose I could spend the 30 hours reformating the data in the db, but that sorta defeats the concept of having dynamic data.

Thanks if anyone can point me in the right direction,

Options: ReplyQuote

Written By
Can I format Query Output?
May 05, 2006 08:03PM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.