PostgreSQL Source Code
git master
rewriteDefine.h
Go to the documentation of this file.
1
/*-------------------------------------------------------------------------
2
*
3
* rewriteDefine.h
4
*
5
*
6
*
7
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
8
* Portions Copyright (c) 1994, Regents of the University of California
9
*
10
* src/include/rewrite/rewriteDefine.h
11
*
12
*-------------------------------------------------------------------------
13
*/
14
#ifndef REWRITEDEFINE_H
15
#define REWRITEDEFINE_H
16
17
#include "
catalog/objectaddress.h
"
18
#include "
nodes/parsenodes.h
"
19
#include "
utils/relcache.h
"
20
21
#define RULE_FIRES_ON_ORIGIN 'O'
22
#define RULE_FIRES_ALWAYS 'A'
23
#define RULE_FIRES_ON_REPLICA 'R'
24
#define RULE_DISABLED 'D'
25
26
extern
ObjectAddress
DefineRule
(
RuleStmt
*
stmt
,
const
char
*queryString);
27
28
extern
ObjectAddress
DefineQueryRewrite
(
const
char
*rulename,
29
Oid
event_relid,
30
Node
*event_qual,
31
CmdType
event_type,
32
bool
is_instead,
33
bool
replace,
34
List
*
action
);
35
36
extern
ObjectAddress
RenameRewriteRule
(
RangeVar
*relation,
const
char
*oldName,
37
const
char
*newName);
38
39
extern
void
setRuleCheckAsUser
(
Node
*node,
Oid
userid);
40
41
extern
void
EnableDisableRule
(
Relation
rel,
const
char
*rulename,
42
char
fires_when);
43
44
#endif
/* REWRITEDEFINE_H */
stmt
#define stmt
Definition:
indent_codes.h:59
generate_unaccent_rules.action
action
Definition:
generate_unaccent_rules.py:287
CmdType
CmdType
Definition:
nodes.h:263
objectaddress.h
parsenodes.h
Oid
unsigned int Oid
Definition:
postgres_ext.h:31
relcache.h
setRuleCheckAsUser
void setRuleCheckAsUser(Node *node, Oid userid)
Definition:
rewriteDefine.c:631
DefineRule
ObjectAddress DefineRule(RuleStmt *stmt, const char *queryString)
Definition:
rewriteDefine.c:190
DefineQueryRewrite
ObjectAddress DefineQueryRewrite(const char *rulename, Oid event_relid, Node *event_qual, CmdType event_type, bool is_instead, bool replace, List *action)
Definition:
rewriteDefine.c:224
EnableDisableRule
void EnableDisableRule(Relation rel, const char *rulename, char fires_when)
Definition:
rewriteDefine.c:691
RenameRewriteRule
ObjectAddress RenameRewriteRule(RangeVar *relation, const char *oldName, const char *newName)
Definition:
rewriteDefine.c:793
List
Definition:
pg_list.h:54
Node
Definition:
nodes.h:129
ObjectAddress
Definition:
objectaddress.h:25
RangeVar
Definition:
primnodes.h:72
RelationData
Definition:
rel.h:56
RuleStmt
Definition:
parsenodes.h:3606
src
include
rewrite
rewriteDefine.h
Generated on Tue Sep 17 2024 06:13:28 for PostgreSQL Source Code by
1.9.1