Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Image Storage, File in DB or File Reference in DB

Options
  • 11-10-2013 10:38am
    #1
    Registered Users Posts: 1,987 ✭✭✭


    Looking for advice on storage of images, there's a website I'm working and each registered user will have a profile picture but there can also be numerous other images associated to the one account.
    As there is the potential for a large amount of images which would be a better plan for storage, store the image as a BLOB and the related information like mime type, file name in three database columns respectively or store the image in a directory and store it's location in one column in the database?

    I'm also trying to think for down the road as the data gets bigger how easy would it be and how reliable if I was to store images as flat files and not in the database, if everything was in the database it's an easier backup/restore process.

    Any advice greatly appreciated, thanks.


Advertisement