Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Importing Data Excel to SQL

Status
Not open for further replies.

onedizzydevil

Programmer
Mar 24, 2001
103
US
I have an Excel spreadsheet with data that I want to import into SQL, I have the SQL table setup correctly. When using the import wizard it always wants to create a new table, it will not give me that ability to choose apend, the column and table name are the same. The SQL table has one seeded identity column that may cause the problem.

Does anyone have any ideas on how to get this accomplished?

Thank you very much

Wayne Sellars

"Programming, today is a race between software developers, striving to build bigger and better idiot-proof programs, and the Universe, trying to produce bigger and better idiots. So far, Universe 1 - Programmers 0."
 

Who is the owner of the table? When you use the wizard, does it select the correct table with the correct owner? Terry L. Broadbent
FAQ183-874 contains tips for posting questions in these forums.
NOTE: Reference to the FAQ is not directed at any individual.
 
The owner of the intended destination table is 'dbo' it creates a new table with the owner of 'dbo'.

I am not 100% for sure about the second part of the question, I think it is, how can I tell for sure?

Wayne Sellars

"Programming, today is a race between software developers, striving to build bigger and better idiot-proof programs, and the Universe, trying to produce bigger and better idiots. So far, Universe 1 - Programmers 0."
 

By default, DTS will attempt to append or create a table with the same name as the worksheet you are importing. You can changge the name of the destination table when you select the source. Click on the destination field and use the pull-down menu to select the correct table. Terry L. Broadbent
FAQ183-874 contains tips for posting questions in these forums.
NOTE: Reference to the FAQ is not directed at any individual.
 
Cool, I can append now. Thanks

However, that leads into another question. I have a seeded identity column in the table and I can import if that is not an identity but it fails if it is.

I have tried using a .xls that does and does not have the colum in it (empty), I have tried using and not using the "Enable identity insert" check box.

Any ideas on this, thank a lot.

Wayne Sellars

"Programming, today is a race between software developers, striving to build bigger and better idiot-proof programs, and the Universe, trying to produce bigger and better idiots. So far, Universe 1 - Programmers 0."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top