Search Postgresql Archives

Re: Problem with partitioning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

2016-08-03 15:29 GMT-03:00 Adrian Klaver <adrian.klaver@xxxxxxxxxxx>:
On 08/03/2016 11:24 AM, JotaComm wrote:


2016-08-03 15:20 GMT-03:00 JotaComm <jota.comm@xxxxxxxxx
<mailto:jota.comm@xxxxxxxxx>>:



    ​When I create a trigger for each child table the trigger works very
    well.​

​​
Without seeing any code this problem is not going to be solved.

​The trigger code:

tg_table_update AFTER UPDATE ON parent_table FOR EACH ROW EXECUTE PROCEDURE f_table_update()

CREATE OR REPLACE FUNCTION f_table_update()

RETURNS TRIGGER AS $$

BEGIN

RAISE NOTICE 'update';

UPDATE parent_table SET date=now() WHERE column_id=OLD.column_id;

RETURN NULL;

END;

$$ LANGUAGE PLPGSQL;
 



            ​Try:

            \d+ <tablename> on the relevant table and check/show the
            "Triggers: " section​.

            David J.


    --
    JotaComm
    http://jotacomm.wordpress.com




--
JotaComm
http://jotacomm.wordpress.com


--
Adrian Klaver
adrian.klaver@xxxxxxxxxxx

​Thank you​


--

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux