Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Java SQL
Hi
 
Im creating a site for a record company that enables users to upload their demos to the site. and when googling around the issue i find that most ppl frown against storing the files in the database.
 
My question is what alternatives do i have to storing the actual file in the database considering the fact that i must be able to retrieve the file from where ever its stored so the clerk may be able to view or listen to it when ever.
 
Kind Regards.
Posted 11-Mar-13 0:57am

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Set up a storage location to hold all the files in a server, could even be the same system that holds the database. Then you just need to store the location of each file in the database for quick access.
  Permalink  
Comments
mlingo209 at 11-Mar-13 6:06am
   
Okay this might sound stupid but do you have any links to tutorials that might show me how to do that ? because I'm honestly clueless.
Richard MacCutchan at 11-Mar-13 6:22am
   
Clueless about what? Do you know how to store a file in a directory? Do you know how to put the pathname of that directory into a database record? If the answer is "no" to both of those questions then you need to do some serious studying.
mlingo209 at 11-Mar-13 7:37am
   
No to the first question what and how do I store in a directory? I'm sure about storing pathname that I can do.
Richard MacCutchan at 11-Mar-13 8:09am
   
Storing a file in a directory, is just a matter of writing it to disk. Storing its path name is just saving the full text string. What is your difficulty?
mlingo209 at 11-Mar-13 8:15am
   
which disk does it get saved to when deployed and available on the net?
Richard MacCutchan at 11-Mar-13 8:48am
   
How can I answer that? It's your project so you need to decide where it gets stored. This is all part of your setup and configuration.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 295
1 DamithSL 265
2 CPallini 235
3 Maciej Los 190
4 George Jonsson 170
0 OriginalGriff 5,415
1 DamithSL 4,422
2 Maciej Los 3,820
3 Kornfeld Eliyahu Peter 3,470
4 Sergey Alexandrovich Kryukov 2,911


Advertise | Privacy | Mobile
Web04 | 2.8.141216.1 | Last Updated 11 Mar 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100