aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>2001-05-14 21:53:16 +0000
committerBruce Momjian <bruce@momjian.us>2001-05-14 21:53:16 +0000
commit783fbdab7059c12aa00df78022a5ae95848e0fcc (patch)
tree75cbdd9580f46570286487a396c822b0b70f83f8 /src
parentc87bc779d4e9f109e92f8b8f1dfad5d6739f8e97 (diff)
downloadpostgresql-783fbdab7059c12aa00df78022a5ae95848e0fcc.tar.gz
postgresql-783fbdab7059c12aa00df78022a5ae95848e0fcc.zip
Remove columns pg_index.haskeytype and pg_index.indisclustered. Not used.
Diffstat (limited to 'src')
-rw-r--r--src/backend/access/gist/gist.c3
-rw-r--r--src/backend/catalog/index.c4
-rw-r--r--src/backend/utils/cache/relcache.c3
-rw-r--r--src/include/catalog/catversion.h4
-rw-r--r--src/include/catalog/pg_index.h17
-rw-r--r--src/interfaces/odbc/info.c29
6 files changed, 15 insertions, 45 deletions
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c
index 06010896821..3326cdecc70 100644
--- a/src/backend/access/gist/gist.c
+++ b/src/backend/access/gist/gist.c
@@ -6,7 +6,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/gist/gist.c,v 1.73 2001/05/07 00:43:15 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/gist/gist.c,v 1.74 2001/05/14 21:53:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1127,7 +1127,6 @@ initGISTstate(GISTSTATE *giststate, Relation index)
elog(ERROR, "initGISTstate: index %u not found",
RelationGetRelid(index));
itupform = (Form_pg_index) GETSTRUCT(htup);
- giststate->haskeytype = itupform->indhaskeytype;
indexrelid = itupform->indexrelid;
ReleaseSysCache(htup);
diff --git a/src/backend/catalog/index.c b/src/backend/catalog/index.c
index 5eefab11489..e2f3d8d27a5 100644
--- a/src/backend/catalog/index.c
+++ b/src/backend/catalog/index.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/catalog/index.c,v 1.146 2001/05/07 00:43:17 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/catalog/index.c,v 1.147 2001/05/14 21:53:16 momjian Exp $
*
*
* INTERFACE ROUTINES
@@ -587,9 +587,7 @@ UpdateIndexRelation(Oid indexoid,
indexForm->indexrelid = indexoid;
indexForm->indrelid = heapoid;
indexForm->indproc = indexInfo->ii_FuncOid;
- indexForm->indisclustered = false;
indexForm->indislossy = islossy;
- indexForm->indhaskeytype = true; /* not actually used anymore */
indexForm->indisunique = indexInfo->ii_Unique;
indexForm->indisprimary = primary;
memcpy((char *) &indexForm->indpred, (char *) predText, predLen);
diff --git a/src/backend/utils/cache/relcache.c b/src/backend/utils/cache/relcache.c
index 780760c095e..7f49b1c56d7 100644
--- a/src/backend/utils/cache/relcache.c
+++ b/src/backend/utils/cache/relcache.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.132 2001/05/14 20:30:20 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.133 2001/05/14 21:53:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -70,7 +70,6 @@ static FormData_pg_attribute Desc_pg_class[Natts_pg_class] = {Schema_pg_class};
static FormData_pg_attribute Desc_pg_attribute[Natts_pg_attribute] = {Schema_pg_attribute};
static FormData_pg_attribute Desc_pg_proc[Natts_pg_proc] = {Schema_pg_proc};
static FormData_pg_attribute Desc_pg_type[Natts_pg_type] = {Schema_pg_type};
-static FormData_pg_attribute Desc_pg_variable[Natts_pg_variable] = {Schema_pg_variable};
static FormData_pg_attribute Desc_pg_log[Natts_pg_log] = {Schema_pg_log};
/*
diff --git a/src/include/catalog/catversion.h b/src/include/catalog/catversion.h
index ab066997fd6..cab2af18d83 100644
--- a/src/include/catalog/catversion.h
+++ b/src/include/catalog/catversion.h
@@ -37,7 +37,7 @@
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Id: catversion.h,v 1.73 2001/05/14 20:30:21 momjian Exp $
+ * $Id: catversion.h,v 1.74 2001/05/14 21:53:16 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -53,6 +53,6 @@
*/
/* yyyymmddN */
-#define CATALOG_VERSION_NO 2001051401
+#define CATALOG_VERSION_NO 2001051402
#endif
diff --git a/src/include/catalog/pg_index.h b/src/include/catalog/pg_index.h
index d0de9252ba3..7c5c0557c90 100644
--- a/src/include/catalog/pg_index.h
+++ b/src/include/catalog/pg_index.h
@@ -8,7 +8,7 @@
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $Id: pg_index.h,v 1.16 2001/01/24 19:43:21 momjian Exp $
+ * $Id: pg_index.h,v 1.17 2001/05/14 21:53:16 momjian Exp $
*
* NOTES
* the genbki.sh script reads this file and generates .bki
@@ -48,7 +48,6 @@ CATALOG(pg_index)
* index */
int2vector indkey;
oidvector indclass;
- bool indisclustered;
bool indislossy; /* do we fetch false tuples (lossy
* compression)? */
bool indhaskeytype; /* does key type != attribute type? */
@@ -70,18 +69,16 @@ typedef FormData_pg_index *Form_pg_index;
* compiler constants for pg_index
* ----------------
*/
-#define Natts_pg_index 12
+#define Natts_pg_index 10
#define Anum_pg_index_indexrelid 1
#define Anum_pg_index_indrelid 2
#define Anum_pg_index_indproc 3
#define Anum_pg_index_indkey 4
#define Anum_pg_index_indclass 5
-#define Anum_pg_index_indisclustered 6
-#define Anum_pg_index_indislossy 7
-#define Anum_pg_index_indhaskeytype 8
-#define Anum_pg_index_indisunique 9
-#define Anum_pg_index_indisprimary 10
-#define Anum_pg_index_indreference 11
-#define Anum_pg_index_indpred 12
+#define Anum_pg_index_indislossy 6
+#define Anum_pg_index_indisunique 7
+#define Anum_pg_index_indisprimary 8
+#define Anum_pg_index_indreference 9
+#define Anum_pg_index_indpred 10
#endif /* PG_INDEX_H */
diff --git a/src/interfaces/odbc/info.c b/src/interfaces/odbc/info.c
index c288cd9fc09..b9728dadab4 100644
--- a/src/interfaces/odbc/info.c
+++ b/src/interfaces/odbc/info.c
@@ -2009,8 +2009,7 @@ SQLStatistics(
char *table_name;
char index_name[MAX_INFO_STRING];
short fields_vector[16];
- char isunique[10],
- isclustered[10];
+ char isunique[10];
SDWORD index_name_len,
fields_vector_len;
TupleNode *row;
@@ -2170,7 +2169,7 @@ SQLStatistics(
indx_stmt = (StatementClass *) hindx_stmt;
sprintf(index_query, "select c.relname, i.indkey, i.indisunique"
- ", i.indisclustered, c.relhasrules"
+ ", c.relhasrules"
" from pg_index i, pg_class c, pg_class d"
" where c.oid = i.indexrelid and d.relname = '%s'"
" and d.oid = i.indrelid", table_name);
@@ -2178,7 +2177,6 @@ SQLStatistics(
result = SQLExecDirect(hindx_stmt, index_query, strlen(index_query));
if ((result != SQL_SUCCESS) && (result != SQL_SUCCESS_WITH_INFO))
{
-
/*
* "Couldn't execute index query (w/SQLExecDirect) in
* SQLStatistics.";
@@ -2226,20 +2224,7 @@ SQLStatistics(
goto SEEYA;
}
- /* bind the "is clustered" column */
result = SQLBindCol(hindx_stmt, 4, SQL_C_CHAR,
- isclustered, sizeof(isclustered), NULL);
- if ((result != SQL_SUCCESS) && (result != SQL_SUCCESS_WITH_INFO))
- {
- stmt->errormsg = indx_stmt->errormsg; /* "Couldn't bind column
- * in SQLStatistics."; */
- stmt->errornumber = indx_stmt->errornumber;
- SQLFreeStmt(hindx_stmt, SQL_DROP);
- goto SEEYA;
-
- }
-
- result = SQLBindCol(hindx_stmt, 5, SQL_C_CHAR,
relhasrules, MAX_INFO_STRING, NULL);
if ((result != SQL_SUCCESS) && (result != SQL_SUCCESS_WITH_INFO))
{
@@ -2270,10 +2255,6 @@ SQLStatistics(
sprintf(buf, "%s_idx_fake_oid", table_name);
set_tuplefield_string(&row->tuple[5], buf);
- /*
- * Clustered index? I think non-clustered should be type OTHER
- * not HASHED
- */
set_tuplefield_int2(&row->tuple[6], (Int2) SQL_INDEX_OTHER);
set_tuplefield_int2(&row->tuple[7], (Int2) 1);
@@ -2316,11 +2297,7 @@ SQLStatistics(
set_tuplefield_string(&row->tuple[4], "");
set_tuplefield_string(&row->tuple[5], index_name);
- /*
- * Clustered index? I think non-clustered should be type
- * OTHER not HASHED
- */
- set_tuplefield_int2(&row->tuple[6], (Int2) (atoi(isclustered) ? SQL_INDEX_CLUSTERED : SQL_INDEX_OTHER));
+ set_tuplefield_int2(&row->tuple[6], (Int2) SQL_INDEX_OTHER);
set_tuplefield_int2(&row->tuple[7], (Int2) (i + 1));
if (fields_vector[i] == OID_ATTNUM)