Fix for indexing problems.
This commit is contained in:
parent
557d295b84
commit
58fdae0ddf
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.25 1998/09/01 04:26:55 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/access/index/indexam.c,v 1.26 1998/09/02 23:05:21 momjian Exp $
|
||||||
*
|
*
|
||||||
* INTERFACE ROUTINES
|
* INTERFACE ROUTINES
|
||||||
* index_open - open an index relation by relationId
|
* index_open - open an index relation by relationId
|
||||||
|
@ -190,23 +190,7 @@ index_insert(Relation relation,
|
||||||
specificResult = (InsertIndexResult)
|
specificResult = (InsertIndexResult)
|
||||||
fmgr(procedure, relation, datum, nulls, heap_t_ctid, heapRel, NULL);
|
fmgr(procedure, relation, datum, nulls, heap_t_ctid, heapRel, NULL);
|
||||||
|
|
||||||
/* ----------------
|
/* must be pfree'ed */
|
||||||
* the insert proc is supposed to return a "specific result" and
|
|
||||||
* this routine has to return a "general result" so after we get
|
|
||||||
* something back from the insert proc, we allocate a
|
|
||||||
* "general result" and copy some crap between the two.
|
|
||||||
*
|
|
||||||
* As far as I'm concerned all this result shit is needlessly c
|
|
||||||
* omplicated and should be eliminated. -cim 1/19/91
|
|
||||||
*
|
|
||||||
* mao concurs. regardless of how we feel here, however, it is
|
|
||||||
* important to free memory we don't intend to return to anyone.
|
|
||||||
* 2/28/91
|
|
||||||
*
|
|
||||||
* this "general result" crap is now gone. -ay 3/6/95
|
|
||||||
* ----------------
|
|
||||||
*/
|
|
||||||
|
|
||||||
return specificResult;
|
return specificResult;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/catalog/indexing.c,v 1.29 1998/09/01 16:21:47 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/catalog/indexing.c,v 1.30 1998/09/02 23:05:23 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -109,12 +109,12 @@ CatalogIndexInsert(Relation *idescs,
|
||||||
HeapTuple index_tup;
|
HeapTuple index_tup;
|
||||||
TupleDesc heapDescriptor;
|
TupleDesc heapDescriptor;
|
||||||
Form_pg_index index_form;
|
Form_pg_index index_form;
|
||||||
Datum datum;
|
Datum datum[INDEX_MAX_KEYS];
|
||||||
|
char nulls[INDEX_MAX_KEYS];
|
||||||
int natts;
|
int natts;
|
||||||
AttrNumber *attnumP;
|
AttrNumber *attnumP;
|
||||||
FuncIndexInfo finfo,
|
FuncIndexInfo finfo,
|
||||||
*finfoP;
|
*finfoP;
|
||||||
char nulls[INDEX_MAX_KEYS];
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
heapDescriptor = RelationGetDescr(heapRelation);
|
heapDescriptor = RelationGetDescr(heapRelation);
|
||||||
|
@ -152,11 +152,11 @@ CatalogIndexInsert(Relation *idescs,
|
||||||
(AttrNumber *) index_form->indkey,
|
(AttrNumber *) index_form->indkey,
|
||||||
heapTuple,
|
heapTuple,
|
||||||
heapDescriptor,
|
heapDescriptor,
|
||||||
&datum,
|
datum,
|
||||||
nulls,
|
nulls,
|
||||||
finfoP);
|
finfoP);
|
||||||
|
|
||||||
indexRes = index_insert(idescs[i], &datum, nulls,
|
indexRes = index_insert(idescs[i], datum, nulls,
|
||||||
&heapTuple->t_ctid, heapRelation);
|
&heapTuple->t_ctid, heapRelation);
|
||||||
if (indexRes)
|
if (indexRes)
|
||||||
pfree(indexRes);
|
pfree(indexRes);
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.80 1998/09/01 04:28:05 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/commands/vacuum.c,v 1.81 1998/09/02 23:05:25 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -1156,7 +1156,7 @@ failed to add item with len = %u to page %u (free space %u, nusd %u, noff %u)",
|
||||||
iresult = index_insert(Irel[i],
|
iresult = index_insert(Irel[i],
|
||||||
idatum,
|
idatum,
|
||||||
inulls,
|
inulls,
|
||||||
&(newtup->t_ctid),
|
&newtup->t_ctid,
|
||||||
onerel);
|
onerel);
|
||||||
if (iresult)
|
if (iresult)
|
||||||
pfree(iresult);
|
pfree(iresult);
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/parser/parse_target.c,v 1.27 1998/09/01 04:30:37 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/parser/parse_target.c,v 1.28 1998/09/02 23:05:27 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -467,7 +467,6 @@ MakeTargetEntryAttr(ParseState *pstate,
|
||||||
int resdomno;
|
int resdomno;
|
||||||
List *attrs = att->attrs;
|
List *attrs = att->attrs;
|
||||||
TargetEntry *tent;
|
TargetEntry *tent;
|
||||||
Oid relid;
|
|
||||||
|
|
||||||
attrname = strVal(lfirst(att->attrs));
|
attrname = strVal(lfirst(att->attrs));
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.33 1998/09/01 04:31:47 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.34 1998/09/02 23:05:30 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
*
|
*
|
||||||
|
@ -65,7 +65,6 @@ static struct ONEXIT
|
||||||
|
|
||||||
static int on_proc_exit_index,
|
static int on_proc_exit_index,
|
||||||
on_shmem_exit_index;
|
on_shmem_exit_index;
|
||||||
static void IpcConfigTip(void);
|
|
||||||
|
|
||||||
typedef struct _PrivateMemStruct
|
typedef struct _PrivateMemStruct
|
||||||
{
|
{
|
||||||
|
@ -739,6 +738,7 @@ LockIsFree(int lockid)
|
||||||
|
|
||||||
#endif /* HAS_TEST_AND_SET */
|
#endif /* HAS_TEST_AND_SET */
|
||||||
|
|
||||||
|
#ifdef NOT_USED
|
||||||
static void
|
static void
|
||||||
IpcConfigTip(void)
|
IpcConfigTip(void)
|
||||||
{
|
{
|
||||||
|
@ -746,3 +746,4 @@ IpcConfigTip(void)
|
||||||
fprintf(stderr, "shared memory or System V IPC semaphore configuration.\n");
|
fprintf(stderr, "shared memory or System V IPC semaphore configuration.\n");
|
||||||
fprintf(stderr, "See the FAQ for more detailed information\n");
|
fprintf(stderr, "See the FAQ for more detailed information\n");
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.18 1998/09/01 04:32:14 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.19 1998/09/02 23:05:34 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -210,7 +210,7 @@ ProcessQueryDesc(QueryDesc *queryDesc)
|
||||||
Query *parseTree;
|
Query *parseTree;
|
||||||
Plan *plan;
|
Plan *plan;
|
||||||
int operation;
|
int operation;
|
||||||
char *tag;
|
char *tag = NULL;
|
||||||
EState *state;
|
EState *state;
|
||||||
TupleDesc attinfo;
|
TupleDesc attinfo;
|
||||||
|
|
||||||
|
|
|
@ -81,8 +81,6 @@ static char *opt_names[] = {
|
||||||
*/
|
*/
|
||||||
int pg_options[NUM_PG_OPTIONS] = {0};
|
int pg_options[NUM_PG_OPTIONS] = {0};
|
||||||
|
|
||||||
static int openlog_done = 0;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Print a timestamp and a message to stdout if the trace flag
|
* Print a timestamp and a message to stdout if the trace flag
|
||||||
* indexed by the flag value is set.
|
* indexed by the flag value is set.
|
||||||
|
|
Loading…
Reference in New Issue