Hi,

I have a database design problem which I'm struggeling with for quite some time. A developer has recommanded me this forum.

I'm developing a website where users can create a folders to store items in. They can also store folders in folders, and folders in those folders, and so on ... You get the picture. You basically never know the depth.

But how to design this in mysql? I have found this tutorial: http://dev.mysql.com/tech-resources/...ical-data.html But I think both methods has there disadvantages. With the first method (Adjacency List Model) you have to know the depth of the folder structure, and with the second method (Nested Set Model) you have to update unbelievable many records if the user has many items in their folders.

At this point I'm thinking to create a second table called 'hierachical' to store the connections between folders and their depth, but I'm not sure how to do this?

Any suggestions? Or is it maybe better to use with a completely other type of database? The project is still in development, so if this is the case, it is still posible.

Thanks for your input!

Christophe