[postgis-users] How to design a database for continents, countries, regions, cities and POIs?
mkubenka at gmail.com
Mon Apr 9 14:58:35 PDT 2012
Actually what we need is some hierarchical base for relationship between
countries, cities, regions, etc. Main goal of the application will be
collecting data from many sources about specific cities, regions,
countries and so on, and store it in database. Let's say we will have city
Rome, we collect some info about this city into database from couple
sources. And we need to know that Rome is in province Rome, sub-region
Lazio in region Lazio, country Italy. So system should be flexible to allow
create such relation from real world.
That's why I would choose two tables:
1) `polygons` - which can store countries, regions, sub-regions, provinces
2) `points` - which can store cities and POIs
On Mon, Apr 9, 2012 at 6:53 PM, Andrea Peri <aperi2007 at gmail.com> wrote:
> >Thank's for your reply.
> >I think we'll go same ways as you describe - use two main tables `polygons`
> >and `points` and couple supporting tables which handle relationships
> >and additional content.
> >Michal K.
> If you plan to use two tables of kind polygons and point, and don't plan
> to use an explicit line table,
> I guess you should use the new postgis topology feature.
> You should create a topology (node,edge,face) and apply a TopoGeometry
> over that topology.
> Where the topogeometry should be the "polygons" you will use in your main
> This approach is really important because otherwise the polygons you will
> use in the main table don't be really topology to each-other.
> Please don't understimate the important of postgis topology.
> Expecially when you plan to describe temathics informations like city
> boundaries, countries and so on.
> The simple relationships between polygons is not sufficient to grant a
> really exact separation between two countries :)
> When we don't use topology we found often some little area where there is
> two or more cities :)
> Andrea Peri
> . . . . . . . . .
> qwerty àèìòù
> postgis-users mailing list
> postgis-users at postgis.refractions.net
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the postgis-users