[web2py] Multiple level database diagram

2012-06-11 Thread Hassan Alnatour
Dear ALL , I am creating an application with is a reference about some city's , so the website has some city's , every city has some areas and every area has some other stuff ,it all up to 6 levels , so what is the best was to do that in the database ? i am thinking about making every lev

Re: [web2py] Multiple level database diagram

2012-06-11 Thread Alec Taylor
What kind of queries are you planning to run on this data? Your answer will help us decide whether this is better to have in few or many tables. Also of relevance are the normal forms (http://en.wikipedia.org/wiki/Database_normalization) On Tue, Jun 12, 2012 at 12:39 AM, Hassan Alnatour wrote:

Re: [web2py] Multiple level database diagram

2012-06-11 Thread hasan alnator
I think some simple queries nothing complex , i will just sort every level by its parent .

Re: [web2py] Multiple level database diagram

2012-06-12 Thread howesc
it's a classic problem of the tradeoff between database normalization and speed. the decisions are guided by the amount of traffic and the type of database you are using. for example if you are using google app engine, where you cannot do joins, i would say 1 table that is completely denormal