Anonymous Asked in Cars &Transportation · 2 weeks ago

Should we store files in database?

In my own experience, it is always better to store files as files. The reason is that the filesystem is optimised for file storeage, whereas a database is not. 12 авг. 2008 г.


Should files be stored in a database?

Reasons in favor of storing files in the database: Having the files and database in sync and able to participate in transactions can be very useful. Files go with the database and cannot be orphaned from it. Backups automatically include the file binaries.

Which database is good for storing files?

Notice that these days most DB (and RDBMS such as PostGreSQL or MySQL and non-SQL DBMS such as MongoDB) are storing their data in files (that is, using raw disk partitions for the storage of DB has become out of fashion).

Can you save file in database?

Yes, generally the best way to store a file in a database is to save the byte array in a BLOB column. You will probably want a couple of columns to additionally store the file's metadata such as name, extension, and so on.

Related Questions

Relevance
Write us your question, the answer will be received in 24 hours