Help please, im trying to use open OPENROWSET to import a csv file into my database
Here is the code im using
and i get this error
OLE DB error trace [OLE/DB Provider 'MSDASQL' IColumnsInfo::G etColumnsInfo returned 0x80004005: The provider did not give any information about the error.].
Msg 7399, Level 16, State 1, Line 1
OLE DB provider 'MSDASQL' reported an error. The provider did not give any information about the error.
I am using OPENROWSET because i can the compare the text file to a table and the update the table base on what is in the text file but not in the table
If anyone knows why i am getting this error please put me out of my misery and help me out
Thanks
Here is the code im using
Code:
--Read CSV using OpenRowSet
select * from OpenRowset('MSDASQL', 'Driver={Microsoft Text Driver (*.txt; *.csv)};
DefaultDir=D:\MSSQL\Data\FUELBCP\;','select top 6 * from
TRANS.csv')
OLE DB error trace [OLE/DB Provider 'MSDASQL' IColumnsInfo::G etColumnsInfo returned 0x80004005: The provider did not give any information about the error.].
Msg 7399, Level 16, State 1, Line 1
OLE DB provider 'MSDASQL' reported an error. The provider did not give any information about the error.
I am using OPENROWSET because i can the compare the text file to a table and the update the table base on what is in the text file but not in the table
If anyone knows why i am getting this error please put me out of my misery and help me out
Thanks
Comment