By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,930 Members | 1,487 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,930 IT Pros & Developers. It's quick & easy.

SQL syntax - leading zeros

P: n/a
I have a Query I'm writing and have a problem:
I have an employee text field (not numeric) with typical values:


When I run my query the leading zeros fall off.
I have to write the solution as a stand-alone query in Access 2000
query design.

I'm thinking something like:

SELECT Employees.GovID
FROM Employees

FORMAT? Format$"000000" ? Format GovID "000000"

Thanks in Advance.... Brian

Jan 5 '06 #1
Share this Question
Share on Google+
4 Replies

P: n/a
I -had- a similar problem with a zip code thing I was working on... is
there a reason why you can't change the field to a numeric field?

Jan 5 '06 #2

P: n/a
It's an ADP purchased software which changing the data type would
affect numerous other functions.

Jan 5 '06 #3

P: n/a wrote:
It's an ADP purchased software

Arghhhhhhh! My Heart! My Heart!

Arghhhhhhh ......!

Jan 5 '06 #4

P: n/a
I'm not local to the user's PC needing this, but how would this work?:

SELECT Format([SomeField], "000000") AS NewNameSomeField

Jan 6 '06 #5

This discussion thread is closed

Replies have been disabled for this discussion.