postgresql_16:7.1.77 CREATE RULE
PostgreSQL 16 > Reference > SQL Commands > CREATE RULE
define a new rewrite rule
CREATE [ OR REPLACE ] RULE name AS ON event
TO table_name [ WHERE condition ]
DO [ ALSO | INSTEAD ] { NOTHING | command | ( command ; command ... ) }
where event can be one of:
SELECT | INSERT | UPDATE | DELETE
CREATE [ OR REPLACE ] RULE name AS ON event
TO table_name [ WHERE condition ]
DO [ ALSO | INSTEAD ] { NOTHING | command | ( command ; command ... ) }
where event can be one of:
SELECT | INSERT | UPDATE | DELETE
Subsections
- postgresql_16:7.1.77.1 Description
- postgresql_16:7.1.77.2 Parameters
- postgresql_16:7.1.77.3 Notes
- postgresql_16:7.1.77.4 Compatibility
- postgresql_16:7.1.77.5 See Also