make one phone number field by appending 3 together?

B

bnicklesaz

I need to have phone number in one field but data base came to me with three
fields: area code/first 3 digits/last 4 digits
How do I get them into one field:?
 
K

Klatuu

First, make a bacup of your database. Be sure it is the one that has the
table in it.
If you have a split database, backing up the front end will do no good.

Now, open your table and add the new field Text, length of 10
(don't put the dashes in the table, use the Format function when you want to
display it)

Now create a Update Query to update the table
(no guarantee the syntax is perfect)

UPDATE MyTable Set PhoneNumber = AreaCode & FirstThree & LastFour;

Use the actual names of your table and fields.
 
C

chris.nebinger

The easiest way:

Add a new field, for phone number (text).

Then, create a query, click on SQL view, then:

Update [TableName] SET [NewFieldName] = [AreaCode] & "-" &
[FirstDigits] & "-" & [SecondDigits]


Chris
 

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