1: Are you expecting massive amounts of data? 2: Do you need versioning of the data? 3: Is the data structured? F.ex. would you like to use the data in more than one place? Does it need it's own url? 4: Who will create/edit the data? Will you editors want to edit the data in the backend?
If we look at comments specifically, then I like the DB approach because it is data that is created once, and not edited. Also, the amount of comments can become massive (think of the spam bots). On my own site, I store comments in the content tree, and the spam bots are using up a lot of node id's in my site, and it is driving me nuts.
It will always be a trade off between having an out of the box editing interface, vs. maybe having to create a CRUD UI yourself. And it depends a bit on how your editors are supposed to work with the content.
Agree with Morten, you shouldn't be using umbraco infrastructure to store data that doesn't need versioning, and no one is ever going to create/edit such data in the admin backend.
Question about data storage...when xml vs. table?
I was just wondering when it is appropriate to us the standard umbraco document to store data vs creating a table in the db to store data?
Take comments for example, it appears that the comments from a Blog4Umbraco package are saved in the Comments table in the database.
Why not just use the umbraco document type to create these entries?
I would typically consider a few factors:
1: Are you expecting massive amounts of data?
2: Do you need versioning of the data?
3: Is the data structured? F.ex. would you like to use the data in more than one place? Does it need it's own url?
4: Who will create/edit the data? Will you editors want to edit the data in the backend?
If we look at comments specifically, then I like the DB approach because it is data that is created once, and not edited. Also, the amount of comments can become massive (think of the spam bots). On my own site, I store comments in the content tree, and the spam bots are using up a lot of node id's in my site, and it is driving me nuts.
It will always be a trade off between having an out of the box editing interface, vs. maybe having to create a CRUD UI yourself. And it depends a bit on how your editors are supposed to work with the content.
Agree with Morten, you shouldn't be using umbraco infrastructure to store data that doesn't need versioning, and no one is ever going to create/edit such data in the admin backend.
Cheers,
/Dirk
That makes perfect sense and helps a ton...thank you very much!
Mike
is working on a reply...