Subject: RETURN NULL in the sample of insert trigger on partitioned table

From: PG Doc comments form <[email-masked]>
Date: Wed, 11 Jul 2018 09:34:59 +0000

The following documentation comment has been logged on the website:

Page: https://www.postgresql.org/docs/9.6/static/ddl-partitioning.html
Description:

Why in provided samples of "insert" triggers on partitioned table at the end
of the triggers you provide "return NULL" not "return NEW"?

This causes, among other things, problems with the GET DIAGNOSTICS clause
var = ROW_COUNT clause.

---

From: Bruce Momjian <[email-masked]>
Date: Tue, 7 Aug 2018 13:57:42 -0400

> This causes, among other things, problems with the GET DIAGNOSTICS clause

Uh, you mean measurement_insert_trigger?  Returning NEW would cause the
row to be inserted into the referenced table.

-- 
  Bruce Momjian  <[email-masked]>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

+ As you are, so once was I.  As I am, so you will be. +
+                      Ancient Roman grave inscription +