aboutsummaryrefslogtreecommitdiff
path: root/src/include/nodes
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/nodes')
-rw-r--r--src/include/nodes/nodes.h3
-rw-r--r--src/include/nodes/parsenodes.h3
-rw-r--r--src/include/nodes/primnodes.h29
3 files changed, 32 insertions, 3 deletions
diff --git a/src/include/nodes/nodes.h b/src/include/nodes/nodes.h
index 3f87ca202ac..9c913797dd4 100644
--- a/src/include/nodes/nodes.h
+++ b/src/include/nodes/nodes.h
@@ -6,7 +6,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: nodes.h,v 1.22 1998/01/10 04:30:08 momjian Exp $
+ * $Id: nodes.h,v 1.23 1998/01/17 04:53:38 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -60,6 +60,7 @@ typedef enum NodeTag
T_Const,
T_Param,
T_Aggreg,
+ T_SubLink,
T_Func,
T_Array,
T_ArrayRef,
diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h
index 02fa069df61..fc30cbf3e0a 100644
--- a/src/include/nodes/parsenodes.h
+++ b/src/include/nodes/parsenodes.h
@@ -6,7 +6,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: parsenodes.h,v 1.45 1998/01/16 23:20:55 momjian Exp $
+ * $Id: parsenodes.h,v 1.46 1998/01/17 04:53:40 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -45,6 +45,7 @@ typedef struct Query
bool isBinary; /* binary portal? */
bool unionall; /* union without unique sort */
bool hasAggs; /* has aggregates in target list */
+ bool hasSubLinks; /* has subquery SubLink */
char *uniqueFlag; /* NULL, '*', or Unique attribute name */
List *sortClause; /* a list of SortClause's */
diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h
index 1e896e5e136..3da2c433cb7 100644
--- a/src/include/nodes/primnodes.h
+++ b/src/include/nodes/primnodes.h
@@ -6,7 +6,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: primnodes.h,v 1.12 1998/01/04 04:31:37 momjian Exp $
+ * $Id: primnodes.h,v 1.13 1998/01/17 04:53:42 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -271,6 +271,33 @@ typedef struct Aggreg
} Aggreg;
/* ----------------
+ * SubLink
+ * subLinkType - EXISTS, ALL, ANY, EXPR
+ * useor - TRUE for <>
+ * lefthand - list of Var/Const nodes on the left
+ * oper - list of Oper nodes
+ * subselect - subselect as Query* or parsetree
+ * ----------------
+ */
+typedef enum SubLinkType
+{
+ EXISTS_SUBLINK, ALL_SUBLINK, ANY_SUBLINK, EXPR_SUBLINK,
+ IN_SUBLINK, NOTIN_SUBLINK, OPER_SUBLINK
+} SubLinkType;
+
+
+typedef struct SubLink
+{
+struct Query;
+ NodeTag type;
+ SubLinkType subLinkType;
+ bool useor;
+ List *lefthand;
+ List *oper;
+ Node *subselect;
+} SubLink;
+
+/* ----------------
* Array
* arrayelemtype - base type of the array's elements (homogenous!)
* arrayelemlength - length of that type