I have a field in SQL that contains a Currency amount, which will be used for an export. It needs to be 13 characters long, preceded by 0 then the dollar amount, without the decimal point.
The field name is DOCAMT. To get the full amount, I'm sure that I need to multiply the currency by 100, but how do I get the dynamic part of the field to be 0's.
Since this will be an export, it would need to be a query instead of vba.
Example:
DOCTAMT= 205.47
Multiplied by 100 gives me 20547, which is correct.
But how do I get 8 0's in front of it, ie. 0000000020547.
The next DOCAMT might be 1234.56 and would need to be 0000000123456
Any ideas?
Thanks
Jeff
The field name is DOCAMT. To get the full amount, I'm sure that I need to multiply the currency by 100, but how do I get the dynamic part of the field to be 0's.
Since this will be an export, it would need to be a query instead of vba.
Example:
DOCTAMT= 205.47
Multiplied by 100 gives me 20547, which is correct.
But how do I get 8 0's in front of it, ie. 0000000020547.
The next DOCAMT might be 1234.56 and would need to be 0000000123456
Any ideas?
Thanks
Jeff
Comment