Re: [partition table] python fetchall or fetchone function can not get the returning rows

Поиск
Список
Период
Сортировка
От Jasen Betts
Тема Re: [partition table] python fetchall or fetchone function can not get the returning rows
Дата
Msg-id jds4cq$j7g$3@reversiblemaps.ath.cx
обсуждение исходный текст
Ответ на [partition table] python fetchall or fetchone function can not get the returning rows  (Xiaoning Xu <xixu@bcgsc.ca>)
Список pgsql-general
On 2011-12-21, Xiaoning Xu <xixu@bcgsc.ca> wrote:
> Hello,
>
> I have a problem concerning the partition table.
> When I store a record into one of the partition and use "RETURNING table_id" or "RETURNING *",
> I expect the same result when calling fetchall or fetchone function as not using partition.
> However, it simply returns nothing.

If you've got a before insert trigger there that does "return false" that's what
happens.

If you need returning to work, you could look at doing the
partitioning in a after insert trigger, deleteing from th main table
and inserting into the partition.

Else perhaps you can use a rule instead, have the rule run a function
and the function return the id.

--
⚂⚃ 100% natural

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

Предыдущее
От: John R Pierce
Дата:
Сообщение: Re: Large Objects and and Vacuum
Следующее
От: "Simon Windsor"
Дата:
Сообщение: Re: Large Objects and and Vacuum