Re: [ADMIN] Partitioning & ORM apps

From: Keith <keith(at)keithf4(dot)com>
To: PropAAS DBA <dba(at)propaas(dot)com>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Re: [ADMIN] Partitioning & ORM apps
Date: 2017-11-20 17:41:20
Message-ID: CAHw75vtebUcMpzatoJr67+wJGGA6uWB2PrO17RWMH=GWyxN0Yw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

If this is a requirement for your application, I would highly recommend
looking into migrating to PostgreSQL 10. The native partitioning methods
allow the RETURNING statements to work as you're expecting. There are
work-arounds for it out there for 9.6 and earlier, but for the life of your
project you would likely be better off getting upgraded to 10 now and
starting your development from there.

On Sat, Nov 18, 2017 at 9:49 PM, PropAAS DBA <dba(at)propaas(dot)com> wrote:

> Hi All;
>
>
> we want to deploy partitioning for historical data archiving & performance
> however the app uses an ORM and depends on the number of rows affected from
> the inserts, updates & deletes which of course always come back as zero
> rows for the partition base or master table.
>
> We talked about letting daily data go into the base table and 'moving' it
> nightly but this could still lead to an update/delete for rown in the child
> tables, thus the same issue remains.
>
>
> Anyone know of a workaround? Maybe it can be done with
> insert/update/delete trigger functions?
>
>
> Thanks in advance
>
>
>
>
> --
> Sent via pgsql-admin mailing list (pgsql-admin(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-admin
>

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message rammohan ganapavarapu 2017-11-20 18:24:04 Re: [ADMIN] Can master and slave on different PG versions?
Previous Message Stephen Frost 2017-11-20 15:34:02 Re: [ADMIN] Migration to pglister - Before