Import and autonumbers

H

Hanne

Is it possible to import data from Excel to an Access
table with primary key as autonumber?
 
L

Liz

Yes, it is.
Set up the table with the proper fields, and the
Autonumber Primary field and then import the Excel data in.

Good Luck!
 
H

Hanne

But I need to have one column in the Excel sheet for each
field in the table? Right? Do I then leave the column for
the primary key empty? I've tried that, but without
success :(
 
L

Liz

Yes, there has to be a field in the table for each column
in the Excel spreadsheet. Call the fields in the Table
the same as the names of the columns. Also! Include a
field that you set as the Autonumber field, name it
whatever you want. When you import the Primary Autonumber
field will automatically populate with the autonumber for
each record.
I tried this in Access 2000 and it worked quite
successfully.

Good Luck!
 
L

Liz

I should clarify.....
The AUTONUMBER FIELD IS ONLY SET UP IN ACCESS, NOT IN THE
EXCEL SHEET.
So add the Autonumber field to the Table, and no
corresponding field in the Excel sheet that is being
imported.
 

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