General question: Filesystem or database?

Posted by poeschlorn on Stack Overflow See other posts from Stack Overflow or by poeschlorn
Published on 2010-05-05T11:43:59Z Indexed on 2010/05/05 11:48 UTC
Read the original article Hit count: 189

Hey guys, i want to create a small document management system. there are several users who store their files. each file which is uploaded contains an info which user uploaded it and the document content itself. In a view there are displayed all files of ONE specific user, ordered by date.

What would be better:

1) giving the documents a name or metadata(XML) which contain the date and user (and iterate through them to get the metadata)

or

2) giving the files a random/unique name and store metadata in a DB? something like this:

date | user | filename

What would you say and why? The used programming language is java and the DB is MySQL.

© Stack Overflow or respective owner

Related posts about database-design

Related posts about Performance