Unable to import one table to another

R

Rob

Hi,

Access 2000, XP

I'm unable to import an Excel file in to an existing Access table. I
started by importing an Excel file into Access and chose this to be a new
table with Access choosing a primary key. This table is called RatioTbl. I
then opened the Excel file and changed a date in each record to one week
later, saved the file and closed Excel. In Access, Table Objects, I chose
New from the menu and then Import Table, I selected the original Excel file
which now had the same data albeit the date in all records was one week
later. I chose to import into an existing table and chose RatioTbl from the
drop down list, then chose Next and Finish. However, I receive the
following message: An error occurred trying to import file 'C:\[name of my
file], the file was not imported.

Any ideas as to why this might be happening?

Thanks, Rob
 
R

rkc

Rob said:
Hi,

Access 2000, XP

I'm unable to import an Excel file in to an existing Access table. I
started by importing an Excel file into Access and chose this to be a new
table with Access choosing a primary key. This table is called RatioTbl. I
then opened the Excel file and changed a date in each record to one week
later, saved the file and closed Excel. In Access, Table Objects, I chose
New from the menu and then Import Table, I selected the original Excel file
which now had the same data albeit the date in all records was one week
later. I chose to import into an existing table and chose RatioTbl from the
drop down list, then chose Next and Finish. However, I receive the
following message: An error occurred trying to import file 'C:\[name of my
file], the file was not imported.

Any ideas as to why this might be happening?

Do you have a primary key defined in the existing table?
You may be trying to import records with duplicate primary key
values.
 
R

Rob

I have primary key in the existing table but not in the one I'm trying to
import. I have tried to include the primary key field which is ID in the
file to be imported in but this makes no difference.

I have also created a new table without primary key and tried to import an
identical file into this i.e. same file imported twice but alas this
generates the same error.

Thanks, Rob

rkc said:
Rob said:
Hi,

Access 2000, XP

I'm unable to import an Excel file in to an existing Access table. I
started by importing an Excel file into Access and chose this to be a new
table with Access choosing a primary key. This table is called
RatioTbl.
I
then opened the Excel file and changed a date in each record to one week
later, saved the file and closed Excel. In Access, Table Objects, I chose
New from the menu and then Import Table, I selected the original Excel file
which now had the same data albeit the date in all records was one week
later. I chose to import into an existing table and chose RatioTbl from the
drop down list, then chose Next and Finish. However, I receive the
following message: An error occurred trying to import file 'C:\[name of my
file], the file was not imported.

Any ideas as to why this might be happening?

Do you have a primary key defined in the existing table?
You may be trying to import records with duplicate primary key
values.
 
R

Rob

I have solved the problem, one of the titles in the first row of my Excel
file has a period (full stop), at the end of the text. Strangely, the file
imports first time but trying us import to amend to the original records
doesn't work!

Regards, Rob

Rob said:
I have primary key in the existing table but not in the one I'm trying to
import. I have tried to include the primary key field which is ID in the
file to be imported in but this makes no difference.

I have also created a new table without primary key and tried to import an
identical file into this i.e. same file imported twice but alas this
generates the same error.

Thanks, Rob

rkc said:
Rob said:
Hi,

Access 2000, XP

I'm unable to import an Excel file in to an existing Access table. I
started by importing an Excel file into Access and chose this to be a new
table with Access choosing a primary key. This table is called
RatioTbl.
I
then opened the Excel file and changed a date in each record to one week
later, saved the file and closed Excel. In Access, Table Objects, I chose
New from the menu and then Import Table, I selected the original Excel file
which now had the same data albeit the date in all records was one week
later. I chose to import into an existing table and chose RatioTbl
from
the
drop down list, then chose Next and Finish. However, I receive the
following message: An error occurred trying to import file 'C:\[name
of
my
file], the file was not imported.

Any ideas as to why this might be happening?

Do you have a primary key defined in the existing table?
You may be trying to import records with duplicate primary key
values.
 

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