Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Transact-SQL (2000)
 importing sample excel file

Author  Topic 

Hitesh Shah
Yak Posting Veteran

80 Posts

Posted - 2007-05-30 : 11:10:36
I am trying to import sample excel file . Here is the code .I use Office 2003 (ie 11) into SQL 2000 SP3a .

create table Staging (
excelRow int identity(1,1) primary key,
s varchar(100)
)


insert into Staging
select F1 from OpenRowSet(
'Microsoft.Jet.OLEDB.4.0',
'Excel 8.0;Database=D:\ipadd.xls;HDR=NO;IMEX=1'
,Sheet1$
)
go


We get the following errors .
Server: Msg 7399, Level 16, State 1, Line 7
OLE DB provider 'Microsoft.Jet.OLEDB.4.0' reported an error. The provider did not give any information about the error.
OLE DB error trace [OLE/DB Provider 'Microsoft.Jet.OLEDB.4.0' IDBInitialize::Initialize returned 0x80004005: The provider did not give any information about the error.].

What could be the issue .

PeterNeo
Constraint Violating Yak Guru

357 Posts

Posted - 2007-05-31 : 00:27:47
Hi Hitesh,

to fix u r error check the following from MS
http://support.microsoft.com/default.aspx/kb/890759

To export- import excel files in different ways u can c the link provided in sql-server-performance.com
http://www.sql-server-performance.com/forum/topic.asp?TOPIC_ID=16132
Go to Top of Page

Hitesh Shah
Yak Posting Veteran

80 Posts

Posted - 2007-05-31 : 00:49:32
Thanks u very much Peter for quick response .
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-05-31 : 01:15:45
Also refer
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=49926

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

Hitesh Shah
Yak Posting Veteran

80 Posts

Posted - 2007-06-01 : 01:00:34
I tried the same on another server where it worked with same configurations . Then on the same server when I tried again I got the same error 7399 on the same XL file . I noticed that 2nd time my XL file was open . So I closed it again and it worked again .

So I realize besides the patches MS is recoomending , it could be something to do with open XL file.

I have not checked the MDAC version with me .
Go to Top of Page
   

- Advertisement -