diff options
Diffstat (limited to 'src/include/nodes/primnodes.h')
| -rw-r--r-- | src/include/nodes/primnodes.h | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h index caa689e262..185673f729 100644 --- a/src/include/nodes/primnodes.h +++ b/src/include/nodes/primnodes.h @@ -10,7 +10,7 @@ * Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/nodes/primnodes.h,v 1.125 2007/02/19 07:03:31 tgl Exp $ + * $PostgreSQL: pgsql/src/include/nodes/primnodes.h,v 1.126 2007/02/20 17:32:17 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -49,6 +49,15 @@ typedef enum InhOption INH_DEFAULT /* Use current SQL_inheritance option */ } InhOption; +/* What to do at commit time for temporary relations */ +typedef enum OnCommitAction +{ + ONCOMMIT_NOOP, /* No ON COMMIT clause (do nothing) */ + ONCOMMIT_PRESERVE_ROWS, /* ON COMMIT PRESERVE ROWS (do nothing) */ + ONCOMMIT_DELETE_ROWS, /* ON COMMIT DELETE ROWS */ + ONCOMMIT_DROP /* ON COMMIT DROP */ +} OnCommitAction; + /* * RangeVar - range variable, used in FROM clauses * @@ -69,6 +78,20 @@ typedef struct RangeVar Alias *alias; /* table alias & optional column aliases */ } RangeVar; +/* + * IntoClause - target information for SELECT INTO and CREATE TABLE AS + */ +typedef struct IntoClause +{ + NodeTag type; + + RangeVar *rel; /* target relation name */ + List *colNames; /* column names to assign, or NIL */ + List *options; /* options from WITH clause */ + OnCommitAction onCommit; /* what do we do at COMMIT? */ + char *tableSpaceName; /* table space to use, or NULL */ +} IntoClause; + /* ---------------------------------------------------------------- * node types for executable expressions |
