Solved

How to export a SQL Server 2008 image field to a pdf file?

Posted on 2014-03-18
3
674 Views
Last Modified: 2014-03-26
I have a table with an image field that is used to store pdf files in binary format. I have successfully imported a pdf file into the image field using openrowset. Then I successfully exported it to a binary file using BCP in a SQLCMD window.

Now my problem is how to get the exported binary file into pdf format so Adobe can read it, and I can confirm that I have the same file I started with.
0
Comment
Question by:chi5927
  • 2
3 Comments
 
LVL 5

Expert Comment

by:dannygonzalez09
ID: 39937485
found an article which i think might help you

http://www.sqlservercentral.com/articles/BCP/63560/
0
 

Accepted Solution

by:
chi5927 earned 0 total points
ID: 39945997
I don't think there's any way to do this other than programmatically. I'm going to try writing a little utility program to do the job. If that doesn't work I will re-post the question.
0
 

Author Closing Comment

by:chi5927
ID: 39955466
I have seen nothing in any of the articles I read to indicate that it's possible to do this in native SQL. I have some code from another application that does it programmatically so I'm going with that.
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question