March 26, 2007 at 10:53 pm
i have 1 table with 3 columns. in 2 column i have file path saved as varchar(20 ).
on the basis of this path i want to read file from destination and then store the contents of read file in the same location as file path means in the same row.
is it possible?
March 27, 2007 at 1:11 am
Hi,
Just to clarify your question; you need to get the filename from the [filename] column, then read the contents of that file and store it in the same row under another column. Am I right?
And you want to do this using SQL Server 2000 DTS?
Gogula
March 27, 2007 at 1:26 am
Ya i have same meaning.
i have 1 table with 3 columns
name filepath doc
in filepath there is stored path of file as c:\manish.doc
i want to store the contents of file c:\manish.doc into doc column in the same table.
how it is possible by any mean either dts or someother mean?
March 27, 2007 at 3:19 am
Hi Manish,
Yes this can be done using DTS. You would only need two Connections objects to the SQL Server (one as the Source and the other as the Destination) and a Data Flow Task.
You could have the [name] and [filepath] fields as the source input and have the [name] and the [doc] fields as the destination output. Then it's just a matter of having an ActiveX script on the Transformation to read the file from the file system using the Scripting FileSystem objects; and set it to the destination, and running an update query.
Of course, you would have to use Office components if you need to read text from the .doc files...
Let me know if you need more clarification of the procedure or a sample.
Regards,
Gogula
March 27, 2007 at 3:37 am
ya pls provide me some examples?
pls help me
March 27, 2007 at 3:37 am
ya pls provide me some examples?
pls help me
March 27, 2007 at 4:15 am
Hi Manish,
There's a sample that I could send you if you could send me a private message with your email on it...
Gogula.
March 27, 2007 at 5:05 am
Viewing 8 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply