Solved

copy from one table to another in access

Posted on 2012-04-02
6
305 Views
Last Modified: 2012-04-02
I was given a table on access database that need to be exported into an existing database in access , the column names are different but the data will fit into the existing table,  there are however columns that will remain null.


How would I do this?  I cannot select copy past since the data is not same order,,,
0
Comment
Question by:TonyReba
  • 3
  • 2
6 Comments
 
LVL 120

Assisted Solution

by:Rey Obrero (Capricorn1)
Rey Obrero (Capricorn1) earned 200 total points
ID: 37799023
you will need to create a query against the source table that will match the fields of the destination table.

if you find it difficult to do this, upload a copy of the source db and destination db.
0
 
LVL 9

Author Comment

by:TonyReba
ID: 37799030
I have both tables now in a same database.

But I need to copy fields from table 2 to table 1,

Is there any nechanism in access to do this , do I have to create a custom query???
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 37799157
<Is there any nechanism in access to do this> Yes, the query i mentioned above
0
DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

 
LVL 9

Author Comment

by:TonyReba
ID: 37799159
How do I run it
0
 
LVL 29

Accepted Solution

by:
IrogSinta earned 300 total points
ID: 37799172
Insert this in a query SQL view.
INSERT INTO DestinationTable (NameOfColumn1, NameOfColumn2) SELECT NameOfSourceColumn1,  NameOfSourceColumn2 FROM SourceTable
0
 
LVL 9

Author Comment

by:TonyReba
ID: 37799258
got it this is the query used:

INSERT INTO tbl_Providers(Provider_Type,Group_Business_Name,Address,Address2,City,State,Zip)
SELECT
ProviderType,
PHARM_NAME,
Address1,
Address2,
CITY,
STATE,
ZIP_CD_5 FROM s ;
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question