This is a discussion on Rounding Down within the Php and MySQL forums, part of the Programming / Scripting / Coding category; So, I want to store a number into a MySQL DB. Except it's numbers like 90.5 or 110.123 and numbers ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| | #1 (permalink) |
| WMT Addict | So, I want to store a number into a MySQL DB. Except it's numbers like 90.5 or 110.123 and numbers like that. If I put it on float, it saves it the way it is. If I put it on integer, it rounds it up. Anyone know how to round it down? Thanks Last edited by SirJinX; 23-05-2005 at 03:29. |
| | |
| | #2 (permalink) |
| WMT Addict | Uhmmm it seems like you answered your own question...put it as an integer...
__________________ Cridiron.com |
| | |
| | #4 (permalink) |
| WMT Addict | Does it round up no matter what? like I know it will round up if it's 5 or over, but will it still round up if it's a number like 12.1? Cause mathematically, it should be rounded down because the decimal is lower than 5.
__________________ Cridiron.com |
| | |
| | #6 (permalink) |
| WMT Addict | Hmmm I don't know...I'm not very good with storing numbers and values into databases. Sorry... You can try googling it though
__________________ Cridiron.com |
| | |