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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Inserting Decimal in numeric field

Status
Not open for further replies.

SR24

Programmer
Jan 14, 2005
19
0
0
US
I have a string field which contains numeric data with leading zero's. I've converted this field to a number field and removed the leading zero's but I am having some trouble inserting a decimal point so I can report the field as a currency amount. For example, the string would appear as 0000001125. I've converted this string to a number and removed the leading zero's so the numeric field displays as 1125. How can I insert a decimal so the field displays as 11.25?
 
Hi,
Maybe divide the number by 100 before the text conversion and use the formatting options of the ToText function to display it correctly?



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Try a formula of:

val({table.field})/100

You don't need to strip out the zeros, just convert it to numeric and change the precision.

-k
 
Thanks for the quick response. It worked great!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top