make one phone number field by appending 3 together?

  • Thread starter Thread starter bnicklesaz
  • Start date Start date
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:?
 
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.
 
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
 
Back
Top