May 7, 2009 at 1:45 am
Hi All,
can any body please tell me the way/querry to store pdf and doc file in database. I am using SQL2005.
May 7, 2009 at 6:50 am
I think that the post below should help.
May 7, 2009 at 7:01 am
create table #ORStable (doclen bigint, doc varbinary(max))
insert into #ORStable
select len(bulkcolumn), * from openrowset(bulk 'C:\TABLEINFO.TXT', SINGLE_BLOB)
as r
select * from #ORStable
select CAST(doc as nvarchar(MAX)) from #ORStable
or search for openrowset
May 7, 2009 at 9:50 am
don't forget the document name so you can restore it back from the image!
create table #ORStable (docname varchar(255), doclen bigint, doc varbinary(max))
Lowell
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply