Reqd help for reading flat text file throgh OLE DB

Reqd help for reading flat text file throgh OLE DB

Post by Bharat Sangan » Tue, 06 Mar 2001 21:28:32



Reqd help for reading flat text  file throgh OLE DB

Dear Sir,

    I am facing problem in reading flat text file throgh SQL 7 query analyser.
    My query is as follows

select * from openrowset('DTSFlatFile'
, 'Data Source=\\myserver\bosac7\t2.txt
;Mode=Read;Row Delimiter={LF};File Format=0;Column Delimiter=|
;File Type=1;Skip Rows=0;First Row Column Name=False
;Number of Column=0;Max characters per delimited column=255'
,'SELECT * ')

    error given is

Server: Msg 7303, Level 16, State 2, Line 1
Could not initialize data source object of OLE DB provider 'DTSFlatFile'.
[OLE/DB provider returned message: Error opening datafile: The system cannot find
the file specified.]

content of text file T2 is

ACC | S R Investment | 500.00
REL | L R Trades | 300.00

Please note that T2.TXT file existing in the same folder as specified in data
source statement and
despite correct path it is giving error.

can u please give solution to the above problem

Thanks

Bharat Sangani

 
 
 

Reqd help for reading flat text file throgh OLE DB

Post by Bob Pfeif » Tue, 06 Mar 2001 22:43:29


Does your MSSQLServer service use a login account that has permissions to
access the network drive your text file is on?

 
 
 

Reqd help for reading flat text file throgh OLE DB

Post by Bhara » Fri, 09 Mar 2001 16:01:21


yes
it has all necessory permissions

Thanks
Bharat

Quote:-----Original Message-----

Does your MSSQLServer service use a login account that has permissions to
access the network drive your text file is on?

.

 
 
 

1. Accessing Flat files through DTS Flat File OLE DB Provider

Hello,

I am interested in defining a DTS package that transforms data from
flat files to SQL Server table.

I would like to access the flat files through the DTS Flat File OLE DB
Provider.

But, I couldn't find any information on how to define the metadata of
the Flat files.

Any help would be appreciated.

Thanks in advance,
Hayim Salti

--== Sent via Deja.com http://www.deja.com/ ==--
---Share what you know. Learn what you don't.---

2. exporting DB objects and data by owner

3. Exporting more than 22 coloumns to a flat text file from MS OLE DB Provider

4. Compact Database with Jet 4.0

5. Using the OLE DB flat file provider to automate DTS w/VB6

6. Java & Script

7. SQL Server DTS Flat File OLE DB Provider

8. Best way to Move Data when ID columns are involved ?

9. help reqd. with text file

10. help reqd writing file io for db

11. Importing from flat text files to relational DB

12. Help - Flat File reading

13. URGENT HELP PLEASE--Tool to parese and read Flat Dat file