Solved

Storing a PDF File as an Image?

Posted on 2014-11-18
6
110 Views
Last Modified: 2014-11-19
I'm saving a PDF file in a SQL Server DB. The column in the Table is defined as varbinary(MAX). I was wondering if the PDF can be stored as an Image DataType? If so, which is more efficient to do? Is there a better way altogether?

If you could provide a code example in VB.Net, I would appreciate it!

Thanks!
0
Comment
Question by:BlakeMcKenna
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 15

Expert Comment

by:David L. Hansen
ID: 40451349
I usually just store the files location in a regular varchar column. Just be sure to store the full path (the full UNC is of course preferable).
0
 
LVL 15

Expert Comment

by:David L. Hansen
ID: 40451354
Your VB program can then use the path's string value (eg. using the IO namespace...ie. IO.File.Open).
0
 

Author Comment

by:BlakeMcKenna
ID: 40452292
I already know how to do this. This isn't related to my question.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 15

Accepted Solution

by:
David L. Hansen earned 500 total points
ID: 40452602
You can use varbinary to hold images. If you want your PDF's to be stored as some other type of image (say Jpeg) they will, of course, need to be converted to that format before placing them in the database.

If the images are very large then my previous comments are a better way to go.  See this article.
0
 

Author Closing Comment

by:BlakeMcKenna
ID: 40452876
Thanks David...that's more what I was looking for!
0
 
LVL 15

Expert Comment

by:David L. Hansen
ID: 40452881
Glad to help Blake!
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

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

This tutorial demonstrates one way to create an application that runs without any Forms but still has a GUI presence via an Icon in the System Tray. The magic lies in Inheriting from the ApplicationContext Class and passing that to Application.Ru…
Well, all of us have seen the multiple EXCEL.EXE's in task manager that won't die even if you call the .close, .dispose methods. Try this method to kill any excels in memory. You can copy the kill function to create a check function and replace the …
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

622 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