Remove KSQO from GUC and move file to _deadcode.

This commit is contained in:
Bruce Momjian 2002-06-16 00:09:12 +00:00
parent b50cbbd66b
commit 0dbfea39f3
8 changed files with 11 additions and 57 deletions

View File

@ -1,5 +1,5 @@
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.118 2002/06/15 19:58:53 momjian Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/runtime.sgml,v 1.119 2002/06/16 00:09:11 momjian Exp $
-->
<Chapter Id="runtime">
@ -759,34 +759,6 @@ env PGOPTIONS='-c geqo=off' psql
</listitem>
</varlistentry>
<varlistentry>
<term><varname>KSQO</varname> (<type>boolean</type>)</term>
<listitem>
<para>
The <firstterm>Key Set Query Optimizer</firstterm>
(<acronym>KSQO</acronym>) causes the query planner to convert
queries whose <literal>WHERE</> clause contains many OR'ed AND
clauses (such as <literal>WHERE (a=1 AND b=2) OR (a=2 AND b=3)
...</literal>) into a union query. This method can be faster
than the default implementation, but it doesn't necessarily give
exactly the same results, since <literal>UNION</> implicitly
adds a <literal>SELECT DISTINCT</> clause to eliminate identical
output rows. <acronym>KSQO</acronym> is commonly used when
working with products like <productname>Microsoft
Access</productname>, which tend to generate queries of this
form.
</para>
<para>
The <acronym>KSQO</acronym> algorithm used to be absolutely
essential for queries with many OR'ed AND clauses, but in
<productname>PostgreSQL</productname> 7.0 and later the standard
planner handles these queries fairly successfully; hence the
default is off.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><varname>RANDOM_PAGE_COST</varname> (<type>floating point</type>)</term>
<listitem>

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.120 2002/06/13 15:10:25 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.121 2002/06/16 00:09:11 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -145,11 +145,6 @@ subquery_planner(Query *parse, double tuple_fraction)
PlannerQueryLevel++;
PlannerInitPlan = NIL;
#ifdef ENABLE_KEY_SET_QUERY
/* this should go away sometime soon */
transformKeySetQuery(parse);
#endif
/*
* Check to see if any subqueries in the rangetable can be merged into
* this query.

View File

@ -4,7 +4,7 @@
# Makefile for optimizer/prep
#
# IDENTIFICATION
# $Header: /cvsroot/pgsql/src/backend/optimizer/prep/Makefile,v 1.12 2000/08/31 16:10:13 petere Exp $
# $Header: /cvsroot/pgsql/src/backend/optimizer/prep/Makefile,v 1.13 2002/06/16 00:09:11 momjian Exp $
#
#-------------------------------------------------------------------------
@ -12,7 +12,7 @@ subdir = src/backend/optimizer/prep
top_builddir = ../../../..
include $(top_builddir)/src/Makefile.global
OBJS = prepqual.o preptlist.o prepunion.o prepkeyset.o
OBJS = prepqual.o preptlist.o prepunion.o
all: SUBSYS.o

View File

@ -8,7 +8,9 @@
*
*-------------------------------------------------------------------------
*/
/* THIS FILE WAS USED FOR KSQO, WHICH IS DISABLED NOW. bjm 2002-06-15 */
#include "postgres.h"
#include "optimizer/planmain.h"

View File

@ -5,7 +5,7 @@
* command, configuration file, and command line options.
* See src/backend/utils/misc/README for more information.
*
* $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.69 2002/05/17 20:32:29 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/misc/guc.c,v 1.70 2002/06/16 00:09:12 momjian Exp $
*
* Copyright 2000 by PostgreSQL Global Development Group
* Written by Peter Eisentraut <peter_e@gmx.net>.
@ -312,11 +312,6 @@ static struct config_bool
{ "enable_hashjoin", PGC_USERSET }, &enable_hashjoin,
true, NULL, NULL
},
{
{ "ksqo", PGC_USERSET }, &_use_keyset_query_optimizer,
false, NULL, NULL
},
{
{ "geqo", PGC_USERSET }, &enable_geqo,
true, NULL, NULL

View File

@ -89,8 +89,6 @@
#enable_mergejoin = true
#enable_hashjoin = true
#ksqo = false
#effective_cache_size = 1000 # default in 8k pages
#random_page_cost = 4
#cpu_tuple_cost = 0.01

View File

@ -3,7 +3,7 @@
*
* Copyright 2000 by PostgreSQL Global Development Group
*
* $Header: /cvsroot/pgsql/src/bin/psql/tab-complete.c,v 1.49 2002/06/15 19:43:47 momjian Exp $
* $Header: /cvsroot/pgsql/src/bin/psql/tab-complete.c,v 1.50 2002/06/16 00:09:12 momjian Exp $
*/
/*----------------------------------------------------------------------
@ -226,7 +226,6 @@ psql_completion(char *text, int start, int end)
"enable_nestloop",
"enable_mergejoin",
"enable_hashjoin",
"ksqo",
"geqo",
"fsync",
"server_min_messages",
@ -695,7 +694,7 @@ psql_completion(char *text, int start, int end)
COMPLETE_WITH_LIST(my_list);
}
else if (strcasecmp(prev2_wd, "GEQO") == 0 || strcasecmp(prev2_wd, "KSQO") == 0)
else if (strcasecmp(prev2_wd, "GEQO") == 0)
{
char *my_list[] = {"ON", "OFF", "DEFAULT", NULL};

View File

@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: planmain.h,v 1.57 2002/05/18 02:25:50 tgl Exp $
* $Id: planmain.h,v 1.58 2002/06/16 00:09:12 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -62,11 +62,4 @@ extern List *join_references(List *clauses, List *rtable,
Index acceptable_rel);
extern void fix_opids(Node *node);
/*
* prep/prepkeyset.c
*/
extern bool _use_keyset_query_optimizer;
extern void transformKeySetQuery(Query *origNode);
#endif /* PLANMAIN_H */