How to upload pdf file in sql Database using Filestream as Datatype

Posted on 2011-05-04
Medium Priority
Last Modified: 2012-05-11
i want to upload/save  a pdf file in sql database

 I used Image as datatype
and found the file is stored as
binary.But storing a large pdf
file can overload the database
due to its size.
Can there is any other process to do that
to minimize the server load.
I also want to restore the file and to read it.

Please provide me the answer
stepwise. and code to do this
Question by:code_me
LVL 16

Expert Comment

by:Imran Javed Zia
ID: 35689078
In a case where you don't want to store files in the server you can do the following

Add a column that may store the path in relalted table.
When going to save file, save the file to some location on file system.
and when you get the data then read that file and add to record set.

alternatively you can use some file source as http location or ftp location to get the files.

LVL 70

Accepted Solution

Éric Moreau earned 2000 total points
ID: 35689079

Author Closing Comment

ID: 35689152
thanks for the link

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…

809 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