From 664604e6cafc6825c2b36df0e4e011366f844ea0 Mon Sep 17 00:00:00 2001 From: steve-chavez Date: Mon, 5 Aug 2019 13:12:26 -0500 Subject: [PATCH] Fix #212, note about view with complex RULEs --- api.rst | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/api.rst b/api.rst index 34aa00188..c54b01937 100644 --- a/api.rst +++ b/api.rst @@ -947,6 +947,12 @@ Updates also support :code:`Prefer: return=representation` plus :ref:`v_filter`. Beware of accidentally updating every row in a table. To learn to prevent that see :ref:`block_fulltable`. +.. warning:: + + Insertion on VIEWs with complex `RULEs `_ might not work out of the box with PostgREST. + It's recommended that you `use triggers instead of RULEs `_. + If you want to keep using RULEs, a workaround is to wrap the VIEW insertion in a stored procedure and call it through the :ref:`s_procs` interface. + .. _bulk_insert: Bulk Insert