1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

heapattr functions now return a Datum, not char *.

This commit is contained in:
Bruce Momjian
1997-09-12 04:09:08 +00:00
parent 6e04b4b20f
commit 1ea01720d5
28 changed files with 177 additions and 188 deletions

View File

@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/executor/execQual.c,v 1.16 1997/09/08 21:43:00 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/executor/execQual.c,v 1.17 1997/09/12 04:07:36 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -305,12 +305,11 @@ ExecEvalVar(Var *variable, ExprContext *econtext, bool *isNull)
return (Datum) tempSlot;
}
result = (Datum)
heap_getattr(heapTuple, /* tuple containing attribute */
buffer, /* buffer associated with tuple */
attnum, /* attribute number of desired attribute */
tuple_type,/* tuple descriptor of tuple */
isNull); /* return: is attribute null? */
result = heap_getattr(heapTuple, /* tuple containing attribute */
buffer, /* buffer associated with tuple */
attnum, /* attribute number of desired attribute */
tuple_type,/* tuple descriptor of tuple */
isNull); /* return: is attribute null? */
/* ----------------
* return null if att is null
@ -530,12 +529,11 @@ GetAttributeByNum(TupleTableSlot *slot,
return (char *) NULL;
}
retval = (Datum)
heap_getattr(slot->val,
slot->ttc_buffer,
attrno,
slot->ttc_tupleDescriptor,
isNull);
retval = heap_getattr(slot->val,
slot->ttc_buffer,
attrno,
slot->ttc_tupleDescriptor,
isNull);
if (*isNull)
return (char *) NULL;
return (char *) retval;
@ -595,12 +593,11 @@ GetAttributeByName(TupleTableSlot *slot, char *attname, bool *isNull)
if (attrno == InvalidAttrNumber)
elog(WARN, "GetAttributeByName: attribute %s not found", attname);
retval = (Datum)
heap_getattr(slot->val,
slot->ttc_buffer,
attrno,
tupdesc,
isNull);
retval = heap_getattr(slot->val,
slot->ttc_buffer,
attrno,
tupdesc,
isNull);
if (*isNull)
return (char *) NULL;
return (char *) retval;