Re: Geographic data sources, queries and questions

Поиск
Список
Период
Сортировка
От Chuck D.
Тема Re: Geographic data sources, queries and questions
Дата
Msg-id 200705232243.46928.pgsql-list@nullmx.com
обсуждение исходный текст
Ответ на Re: Geographic data sources, queries and questions  (Jorge Godoy <jgodoy@gmail.com>)
Список pgsql-general
On Wednesday 23 May 2007 18:59, you wrote:

>
> I don't believe this is good design.  You'll have to have a trigger or
> something to verify that the country_id+state_id on the city table are
> exactly equal to the country_id+state_id on the state table.  If you
> don't, you might have something like (using US city names...) "country:
> USA -> state: NY" -> "country: Zimbabwe -> state: NY -> city: New
> York".

>
> It isn't a problem of "any country and any state" on the city table, but
> a problem of "this state inside that particular country".  I'd drop the
> country column.

You are right, this is a bad design.  The country_id on the city table has to
go.

В списке pgsql-general по дате отправления:

Предыдущее
От: "Chuck D."
Дата:
Сообщение: Re: Geographic data sources, queries and questions
Следующее
От: Guy Rouillier
Дата:
Сообщение: Re: the future of pljava development