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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

import excel document from network 1

Status
Not open for further replies.

mimi2

Technical User
Apr 2, 2002
407
CA
Hello,
I am totally new to this.
I need to import the data in an execl document to a database.
How can i do that.
Thanks a lot.
 
Open Enterprise Manager and drill down to the database that you want to import data into. Right-click on the database name and choose All Tasks > then Import Data... from the menu. Step through the wizard to define the source spreadsheet and destination table and data to be copied. The wizard is fairly explanatory. Give it a shot and see how you do. Good luck!

--Angel [rainbow]
-----------------------------------
Every time I lose my mind, I wonder
if it's really worth finding.
 
i don't find any thing that asks for excel file import.
i know how to do it for databases.
thanks.
 
On the second step of the wizrd where you define the source of the import, select Microsoft Excel (whichever version is appropriate) from the Data Source drop-down box, then fill in the File name field. Continue with the wizard to define the destination database and table.

--Angel [rainbow]
-----------------------------------
Every time I lose my mind, I wonder
if it's really worth finding.
 
Thanks a lot. It worked.
I always wondered how people did that !
 
Hello again,
my excel file contains 13723 rows and my table once i imported the file contains 26366 rows !!!
what's wrong ?
thanks for any hint.
 
I'm not sure. The row count is almost double what your source file was. Is there any duplication of rows? Could the import process have run twice? What's on row 26366 of the spreadsheet? I believe DTS will import all rows up to the last value.

--Angel [rainbow]
-----------------------------------
Every time I lose my mind, I wonder
if it's really worth finding.
 
Thanks for answering.

I imported Microsoft Excel 97-2000 file
Then i had a choice for :
Sheet1$, sheet1$Print_area, Sheet1$print_titles

when i choose the first one, the number of rows=26366,
for the second one 13721 and i get an error for the third one "too many fields defined"

the titles for the fields are the same for choice #1 but they contain the first data in choice #2. i had to rename the titles. this is why i have 13721 instead of 13722, i guess.



 
Glad to help. Thanks for the star. [smile] Happy coding!

--Angel [rainbow]
-----------------------------------
Every time I lose my mind, I wonder
if it's really worth finding.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top