diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2000-10-26 21:38:24 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2000-10-26 21:38:24 +0000 |
commit | 2f35b4efdbec6c161ca9bd491d6345134910c425 (patch) | |
tree | 2424351bcc12a8ddf2b716b28f53d2c37c79e507 /src/backend/executor/functions.c | |
parent | c9476bafdb1b97d0d21d92788f93298962145479 (diff) | |
download | postgresql-2f35b4efdbec6c161ca9bd491d6345134910c425.tar.gz postgresql-2f35b4efdbec6c161ca9bd491d6345134910c425.zip |
Re-implement LIMIT/OFFSET as a plan node type, instead of a hack in
ExecutorRun. This allows LIMIT to work in a view. Also, LIMIT in a
cursor declaration will behave in a reasonable fashion, whereas before
it was overridden by the FETCH count.
Diffstat (limited to 'src/backend/executor/functions.c')
-rw-r--r-- | src/backend/executor/functions.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/backend/executor/functions.c b/src/backend/executor/functions.c index 58fb68a6113..e5a5e55ef8d 100644 --- a/src/backend/executor/functions.c +++ b/src/backend/executor/functions.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/executor/functions.c,v 1.38 2000/08/24 03:29:03 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/executor/functions.c,v 1.39 2000/10/26 21:35:15 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -135,9 +135,6 @@ init_execution_state(char *src, Oid *argOidVect, int nargs) None); estate = CreateExecutorState(); - if (queryTree->limitOffset != NULL || queryTree->limitCount != NULL) - elog(ERROR, "LIMIT clause from SQL functions not yet implemented"); - if (nargs > 0) { int i; @@ -328,7 +325,7 @@ postquel_getnext(execution_state *es) feature = (LAST_POSTQUEL_COMMAND(es)) ? EXEC_RETONE : EXEC_RUN; - return ExecutorRun(es->qd, es->estate, feature, (Node *) NULL, (Node *) NULL); + return ExecutorRun(es->qd, es->estate, feature, 0L); } static void |