diff options
Diffstat (limited to 'src/include/nodes/primnodes.h')
-rw-r--r-- | src/include/nodes/primnodes.h | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/src/include/nodes/primnodes.h b/src/include/nodes/primnodes.h index 23dff8ed622..57827ee76fe 100644 --- a/src/include/nodes/primnodes.h +++ b/src/include/nodes/primnodes.h @@ -10,7 +10,7 @@ * Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $Id: primnodes.h,v 1.85 2003/06/25 21:30:33 momjian Exp $ + * $Id: primnodes.h,v 1.86 2003/06/29 00:33:44 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -335,6 +335,25 @@ typedef struct OpExpr typedef OpExpr DistinctExpr; /* + * ScalarArrayOpExpr - expression node for "scalar op ANY/ALL (array)" + * + * The operator must yield boolean. It is applied to the left operand + * and each element of the righthand array, and the results are combined + * with OR or AND (for ANY or ALL respectively). The node representation + * is almost the same as for the underlying operator, but we need a useOr + * flag to remember whether it's ANY or ALL, and we don't have to store + * the result type because it must be boolean. + */ +typedef struct ScalarArrayOpExpr +{ + Expr xpr; + Oid opno; /* PG_OPERATOR OID of the operator */ + Oid opfuncid; /* PG_PROC OID of underlying function */ + bool useOr; /* true for ANY, false for ALL */ + List *args; /* the scalar and array operands */ +} ScalarArrayOpExpr; + +/* * BoolExpr - expression node for the basic Boolean operators AND, OR, NOT * * Notice the arguments are given as a List. For NOT, of course the list |