Need Leading Zeros When Changing Field Data Formats

  • Thread starter Thread starter Brad
  • Start date Start date
B

Brad

Help Appreciated,

I have a table field that is a number field containing 6 digits. I need to
change this field to a text field for a web page and retain the leading
zeros (where they exist). Is it possible?

Please Advise,

Brad
 
Help Appreciated,

I have a table field that is a number field containing 6 digits. I need to
change this field to a text field for a web page and retain the leading
zeros (where they exist). Is it possible?

I'd suggest creating a new six-byte Text field in your table; run an
Update query updating it to

Format([numberfield], "000000")

Check to make sure everything's working and then delete the number
field - if the value isn't being used for calculation, it probably
should be Text not Number.
 
John,

Excellent solution. Thank yo so much for your help.

Brad


John Vinson said:
Help Appreciated,

I have a table field that is a number field containing 6 digits. I need to
change this field to a text field for a web page and retain the leading
zeros (where they exist). Is it possible?

I'd suggest creating a new six-byte Text field in your table; run an
Update query updating it to

Format([numberfield], "000000")

Check to make sure everything's working and then delete the number
field - if the value isn't being used for calculation, it probably
should be Text not Number.
 
Back
Top