Re: Bulkloading using COPY - ignore duplicates?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Bulkloading using COPY - ignore duplicates?
Дата
Msg-id 13185.1008687848@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Bulkloading using COPY - ignore duplicates?  (Lee Kindness <lkindness@csl.co.uk>)
Ответы Re: Bulkloading using COPY - ignore duplicates?  (Lee Kindness <lkindness@csl.co.uk>)
Список pgsql-hackers
Lee Kindness <lkindness@csl.co.uk> writes:
> You're right - I was meaning 'SELECT DISTINCT ON ()'. However I'm only
> using it as an example of where the database is choosing (be it
> randomly) the data to discarded.

Not a good example to support your argument.  The entire point of
DISTINCT ON (imho) is that the rows that are kept or discarded are
*not* random, but can be selected by the user by specifying additional
sort columns.  DISTINCT ON would be pretty useless if it weren't for
that flexibility.  The corresponding concept in COPY will need to
provide flexible means for deciding which row to keep and which to
drop, else it'll be pretty useless.
        regards, tom lane


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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Concerns about this release
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Connection Pooling, a year later