Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

decimal value conversion

Status
Not open for further replies.

parames

MIS
Jun 26, 2000
71
MY

Hi List,

I'm using Mysql database. One of the field stores number with 5 decimal points. For example, 125.00252. How to display this field value with 3 decimal point value?? ex: the above number should be displayed, 125.003.
(without changing the database value)
Please help..

thanks a lot,
parames.s
 
Oops. If you are in VB Script then
Code:
FormatNumber(Expression[,NumDigitsAfterDecimal [,IncludeLeadingDigit [,UseParensForNegativeNumbers [,GroupDigits]]]])

strDec = FormatNumber(MyNum + .0005,3)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top