diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2008-10-28 22:02:06 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2008-10-28 22:02:06 +0000 |
commit | e3e3d2a789e34ff6572bdf693beb1516a228c5ff (patch) | |
tree | c5c95ccfe1f4cc79e49c572b13681f628a212fe9 /src/backend/utils/fmgr | |
parent | a80a12247a99f0bccf47bed5786f28a35fc80845 (diff) | |
download | postgresql-e3e3d2a789e34ff6572bdf693beb1516a228c5ff.tar.gz |
Extend ExecMakeFunctionResult() to support set-returning functions that return
via a tuplestore instead of value-per-call. Refactor a few things to reduce
ensuing code duplication with nodeFunctionscan.c. This represents the
reasonably noncontroversial part of my proposed patch to switch SQL functions
over to returning tuplestores. For the moment, SQL functions still do things
the old way. However, this change enables PL SRFs to be called in targetlists
(observe changes in plperl regression results).
Diffstat (limited to 'src/backend/utils/fmgr')
-rw-r--r-- | src/backend/utils/fmgr/README | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/backend/utils/fmgr/README b/src/backend/utils/fmgr/README index 7cdb69418c..ccf911e62e 100644 --- a/src/backend/utils/fmgr/README +++ b/src/backend/utils/fmgr/README @@ -1,4 +1,4 @@ -$PostgreSQL: pgsql/src/backend/utils/fmgr/README,v 1.13 2008/05/15 00:17:40 tgl Exp $ +$PostgreSQL: pgsql/src/backend/utils/fmgr/README,v 1.14 2008/10/28 22:02:05 tgl Exp $ Function Manager ================ @@ -432,8 +432,7 @@ function is called in). The function stores pointers to the Tuplestore and TupleDesc into ReturnSetInfo, sets returnMode to indicate materialize mode, and returns null. isDone is not used and should be left at ExprSingleResult. -If the function is being called as a table function (ie, it appears in a -FROM item), then the expected tuple descriptor is passed in ReturnSetInfo; +If available, the expected tuple descriptor is passed in ReturnSetInfo; in other contexts the expectedDesc field will be NULL. The function need not pay attention to expectedDesc, but it may be useful in special cases. |