Formatting a Number in a Query Field

B

Brad

All,

I have a field value that is formatted currency. I need to format the field
in a query to have leading zeros and retain the decimal values without the
decimal.

Example: Field A= 137.19 I need to convert it to 0013719.

I've attempted to convert it to a string and format it to"0000000", but that
just rounded the number and did not retain the decimal values.

I've also tried using the FormatNumber and Val functions without success.

Any guidance you could give me would be greatly appreciated.

Thanks in advance.
 
F

fredg

All,

I have a field value that is formatted currency. I need to format the field
in a query to have leading zeros and retain the decimal values without the
decimal.

Example: Field A= 137.19 I need to convert it to 0013719.

I've attempted to convert it to a string and format it to"0000000", but that
just rounded the number and did not retain the decimal values.

I've also tried using the FormatNumber and Val functions without success.

Any guidance you could give me would be greatly appreciated.

Thanks in advance.

NewColumn:Format([NumberField]*100,"0000000")
 
B

Brad

Fredg,

Thank you, so simple a solution I completely over looked it.

Thanks, again!


fredg said:
All,

I have a field value that is formatted currency. I need to format the
field
in a query to have leading zeros and retain the decimal values without
the
decimal.

Example: Field A= 137.19 I need to convert it to 0013719.

I've attempted to convert it to a string and format it to"0000000", but
that
just rounded the number and did not retain the decimal values.

I've also tried using the FormatNumber and Val functions without success.

Any guidance you could give me would be greatly appreciated.

Thanks in advance.

NewColumn:Format([NumberField]*100,"0000000")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top