Storing/Retrieving Files In Database

C

Cindy

Hi. I'm using SQL Server 2005. I'd like to know if anyone has any
reference on how to allow users to upload a file **onto a database**.
In other words, a user can have several related files belonging to
him. Also, I would need a syntax that allowed me to retrieve those
files.

I'm sure this is possible. Aside from that information, can anyone
suggest whether this is the proper method? I know I can simply store
the paths, but starting to juggle various directories is not really my
cup of tea; if there is only one directory to store all the files,
some of them might have the same name, thus creating a conflict. That
is something I do not need to worry about if everything is stored in a
table image field.

In any case, thank you in advance for your help.

Cindy
 
G

Guest

Hi.  I'm using SQL Server 2005.  I'd like to know if anyone has any
reference on how to allow users to upload a file **onto a database**.
In other words, a user can have several related files belonging to
him.  Also, I would need a syntax that allowed me to retrieve those
files.

I'm sure this is possible.  Aside from that information, can anyone
suggest whether this is the proper method?  I know I can simply store
the paths, but starting to juggle various directories is not really my
cup of tea; if there is only one directory to store all the files,
some of them might have the same name, thus creating a conflict.  That
is something I do not need to worry about if everything is stored in a
table image field.

In any case, thank you in advance for your help.

Cindy

http://www.google.com/search?hl=en&q=asp.net+upload+file+into+database
 
G

Guest

If you are asking whether file data should be stored in a database, that's
really up to you. Many people store the files on the filesystem and only have
a database entry that points to the file location. Regarding "bloat" that
should not be an issue as long as the table(s) are properly indexed.

-- Peter
Site:http://www.eggheadcafe.com
UnBlog:http://petesbloggerama.blogspot.com
Short Urls & more:http://ittyurl.net







- Show quoted text -

I agree with Peter.

Sharepoint / WSS stores the files in SQL Server (can this be an answer
to the question about proper way? :) I'm also working at the moment
on a similar application that keeps files saved in the database. I
decided to do this because of easy backup, synchronization and role-
based security.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,990
Messages
2,570,211
Members
46,799
Latest member
Mercury_Dev

Latest Threads

Top