I have a File Uploader in my ASP.NET application Using C#, we can upload any type like images, documents, pdf etc.
I m storing it in the Filesystem and having only the Name of the File in DB.
My doubt is can we store the entire file, images in DB. State me Which is good practice and why we need to use it.
Either file System Storage or SQL DB Storage.
Almost the same question was asked here. Check the answer:
Working with images in WCF
It mostly depends on the size of your files. Here’s a nice article.
To BLOB or Not To BLOB
For less than 256kb files storing in DB in VarBinary column is more efficient.
We store our files in MS SQL Server in a VarBinary column with 256kb restriction and it works fine.
Hope it helps. Good Luck!