Re: Partitioning and ORM tools

From: Chris Travers <chris(dot)travers(at)gmail(dot)com>
To: CS DBA <cs_dba(at)consistentstate(dot)com>
Cc: Postgres General <pgsql-general(at)postgresql(dot)org>
Subject: Re: Partitioning and ORM tools
Date: 2016-03-23 08:48:20
Message-ID: CAKt_Zfs40D8SqE2EaD72E4r2AK_L739qik-fGkUkivTLGqtdwQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Mar 23, 2016 at 9:39 AM, Chris Travers <chris(dot)travers(at)gmail(dot)com>
wrote:

> Use a view with a DO INSTEAD trigger. That will allow you to return the
> tuple properly.
>
> On Tue, Mar 22, 2016 at 7:40 PM, CS DBA <cs_dba(at)consistentstate(dot)com>
> wrote:
>
>> Hi All;
>>
>> we setup partitioning for a large table but had to back off because the
>> return status (i.e: "INSERT 0 1") returns "INSERT 0 0" when inserting into
>> the partitioned table which causes the ORM tool to assume the insert
>> inserted 0 rows. Is there a standard / best practices work around for this?
>>
>
Apologies for the top post above.

Just noting additionally that the view with DO INSTEAD approach was
suggested to me by Matt Trout (major contributor to the DBIx::Class ORM in
Perl.

I have used it. It works well. I think it is the best practice there.

>
>> Thanks in advance
>>
>>
>>
>>
>> --
>> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-general
>>
>
>
>
> --
> Best Wishes,
> Chris Travers
>
> Efficito: Hosted Accounting and ERP. Robust and Flexible. No vendor
> lock-in.
> http://www.efficito.com/learn_more
>

--
Best Wishes,
Chris Travers

Efficito: Hosted Accounting and ERP. Robust and Flexible. No vendor
lock-in.
http://www.efficito.com/learn_more

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message zh1029 2016-03-23 10:27:45 Doesn't PostgreSQL clean data in data file after delete records form table?
Previous Message Chris Travers 2016-03-23 08:39:32 Re: Partitioning and ORM tools