summaryrefslogtreecommitdiff
path: root/src/include/commands/sequence.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2000-06-11 20:08:01 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2000-06-11 20:08:01 +0000
commit3477957b44baf2b53f95207ff8824a0361301a2e (patch)
treed3b15fe37f59cc4423a59a734d65dd48615fb265 /src/include/commands/sequence.h
parente9acba1aded0caf2f7e02e8f1bbb813207d8cc8d (diff)
Update sequence-related functions to new fmgr style. Remove downcasing,
quote-stripping, and acl-checking tasks for these functions from the parser, and do them at function execution time instead. This fixes the failure of pg_dump to produce correct output for nextval(Foo) used in a rule, and also eliminates the restriction that the argument of these functions must be a parse-time constant.
Diffstat (limited to 'src/include/commands/sequence.h')
-rw-r--r--src/include/commands/sequence.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/include/commands/sequence.h b/src/include/commands/sequence.h
index f602a6cb392..d695caa2df9 100644
--- a/src/include/commands/sequence.h
+++ b/src/include/commands/sequence.h
@@ -9,10 +9,11 @@
#ifndef SEQUENCE_H
#define SEQUENCE_H
+#include "fmgr.h"
#include "nodes/parsenodes.h"
/*
- * Columns of a sequnece relation
+ * Columns of a sequence relation
*/
#define SEQ_COL_NAME 1
@@ -27,10 +28,11 @@
#define SEQ_COL_FIRSTCOL SEQ_COL_NAME
#define SEQ_COL_LASTCOL SEQ_COL_CALLED
+extern Datum nextval(PG_FUNCTION_ARGS);
+extern Datum currval(PG_FUNCTION_ARGS);
+extern Datum setval(PG_FUNCTION_ARGS);
+
extern void DefineSequence(CreateSeqStmt *stmt);
-extern int4 nextval(struct varlena * seqname);
-extern int4 currval(struct varlena * seqname);
-extern int4 setval(struct varlena * seqname, int4 next);
extern void CloseSequences(void);
#endif /* SEQUENCE_H */