| the Manx Man's MS Access Pages
Adding Zeroes to the Start of a Numeric Field (013) If you need a numeric field with leading zeroes, do this. (I assume integer or long integer) Change the field to a text field, the correct size. Access will convert the data from numbers to text fine. Create an update query with the field in it. In the Update To cell, put a formula like this: right(("0000" & [original_field_name]),4) This assumes you want a field 4 characters in size. Modify to suit. (see tip012 for another use of this technique)
|
tip # 013 || previous tip || next tip