From 1ee26b776475155ad1fb00fa3ed0a93659ffadad Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Sun, 18 Jun 2000 22:44:35 +0000 Subject: Reimplement nodeMaterial to use a temporary BufFile (or even memory, if the materialized tupleset is small enough) instead of a temporary relation. This was something I was thinking of doing anyway for performance, and Jan says he needs it for TOAST because he doesn't want to cope with toasting noname relations. With this change, the 'noname table' support in heap.c is dead code, and I have accordingly removed it. Also clean up 'noname' plan handling in planner --- nonames are either sort or materialize plans, and it seems less confusing to handle them separately under those names. --- src/backend/nodes/readfuncs.c | 40 +++------------------------------------- 1 file changed, 3 insertions(+), 37 deletions(-) (limited to 'src/backend/nodes/readfuncs.c') diff --git a/src/backend/nodes/readfuncs.c b/src/backend/nodes/readfuncs.c index 99d25696ced..f872d952d03 100644 --- a/src/backend/nodes/readfuncs.c +++ b/src/backend/nodes/readfuncs.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.90 2000/06/16 05:27:03 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.91 2000/06/18 22:44:05 tgl Exp $ * * NOTES * Most of the read functions for plan nodes are tested. (In fact, they @@ -555,38 +555,10 @@ _readTidScan() return local_node; } -/* ---------------- - * _readNoname - * - * Noname is a subclass of Plan - * ---------------- - */ -static Noname * -_readNoname() -{ - Noname *local_node; - char *token; - int length; - - local_node = makeNode(Noname); - - _getPlan((Plan *) local_node); - - token = lsptok(NULL, &length); /* eat :nonameid */ - token = lsptok(NULL, &length); /* get nonameid */ - local_node->nonameid = atol(token); - - token = lsptok(NULL, &length); /* eat :keycount */ - token = lsptok(NULL, &length); /* get keycount */ - local_node->keycount = atoi(token); - - return local_node; -} - /* ---------------- * _readSort * - * Sort is a subclass of Noname + * Sort is a subclass of Plan * ---------------- */ static Sort * @@ -600,10 +572,6 @@ _readSort() _getPlan((Plan *) local_node); - token = lsptok(NULL, &length); /* eat :nonameid */ - token = lsptok(NULL, &length); /* get nonameid */ - local_node->nonameid = atol(token); - token = lsptok(NULL, &length); /* eat :keycount */ token = lsptok(NULL, &length); /* get keycount */ local_node->keycount = atoi(token); @@ -625,7 +593,7 @@ _readAgg() /* ---------------- * _readHash * - * Hash is a subclass of Noname + * Hash is a subclass of Plan * ---------------- */ static Hash * @@ -1853,8 +1821,6 @@ parsePlanString(void) return_value = _readIndexScan(); else if (length == 7 && strncmp(token, "TIDSCAN", length) == 0) return_value = _readTidScan(); - else if (length == 6 && strncmp(token, "NONAME", length) == 0) - return_value = _readNoname(); else if (length == 4 && strncmp(token, "SORT", length) == 0) return_value = _readSort(); else if (length == 6 && strncmp(token, "AGGREG", length) == 0) -- cgit v1.2.3