Format number with a space and leading zeros

dcollins

Registered User.
Local time
Today, 10:42
Joined
Nov 24, 2003
Messages
30
I am pulling data out of a new system and need to import it into a really old legacy system. The format this old system needs looks like this (notice the leading space in the first row):
12,116050,4523, 000000253177
12,160310,0680,-000000030000

The last field is a number field that comes in as 2531.77 and -300. I import data into a table and then am using a query to format an export. Getting the leading zeros is not a problem but I need to get a space in front of any number that does not have a "-". Any ideas on how I can get a space in front of the leading zeros but no space if there is a "-"?
Thanks.
 
IIF({originalnumber}<0,"-" & {expression}, {expression})
 
Thank you! Exactly what I needed.
 

Users who are viewing this thread

Back
Top Bottom