new field based on another field in the same table

G

Guest

I need to create a 5-digit zip field from another zip field that has a
combination of 5 and 9 digit zips. In Excel, I would just create a new
column using left(zip code,5). How do I do this in Access? The table is too
large to use Excel.
 
J

John Vinson

I need to create a 5-digit zip field from another zip field that has a
combination of 5 and 9 digit zips. In Excel, I would just create a new
column using left(zip code,5). How do I do this in Access? The table is too
large to use Excel.

You can't (and shouldn't!) do it in a Table. Instead, use a Query; in
a vacant Field cell in the query type

Zip5: Left([zip code], 5)

It is neither necessary nor beneficial to store this derived data in
the table - you can use this calculated field for sorting, querying,
for display on a Form or Report, anything except editing it (which you
would NOT want to do, since it makes no sense to have Zip 83660-6354
in the same record with Zip5 72712).

John W. Vinson[MVP]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top