Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Add zero to beginning of field

Status
Not open for further replies.

Spott

Technical User
Mar 11, 2002
21
0
0
US
We're updating employee numbers from 4 digits (1234) to five digits and padding the existing numbers with a zero in front (01234) I know there's a simple way to update this, adding the zero in front through a query, but I'm stuck! Help!!
 
update myfield set myfield=format(myfield,"00000")

Mike Pastore

Hats off to (Roy) Harper
 
I think I tried it correctly and my numbers still come up 1111, 2222, 3333 instead of 01111, 02222, 03333...

[field1]=Format([field1],"00000")
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top