From 725a03eb4b5afd11814733d8cfeb1dcbd2b97a84 Mon Sep 17 00:00:00 2001
From: Bruce Momjian <bruce@momjian.us>
Date: Sat, 27 Sep 1997 14:37:21 +0000
Subject: [PATCH] Make GetAttributeByNum visible again for external use.

---
 src/backend/executor/execQual.c | 11 ++++++-----
 src/include/executor/executor.h |  7 ++++---
 2 files changed, 10 insertions(+), 8 deletions(-)

diff --git a/src/backend/executor/execQual.c b/src/backend/executor/execQual.c
index 4d96bdb0ada..171277da036 100644
--- a/src/backend/executor/execQual.c
+++ b/src/backend/executor/execQual.c
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *	  $Header: /cvsroot/pgsql/src/backend/executor/execQual.c,v 1.18 1997/09/22 04:19:36 vadim Exp $
+ *	  $Header: /cvsroot/pgsql/src/backend/executor/execQual.c,v 1.19 1997/09/27 14:37:10 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -506,8 +506,11 @@ ExecEvalParam(Param *expression, ExprContext *econtext, bool *isNull)
  *		to use this.  Ex: overpaid(EMP) might call GetAttributeByNum().
  * ----------------
  */
-#ifdef NOT_USED
-static char *
+/*
+ * This gets called from external functions, so don't make it static
+ * or remove it
+ */
+char *
 GetAttributeByNum(TupleTableSlot *slot,
 				  AttrNumber attrno,
 				  bool *isNull)
@@ -539,8 +542,6 @@ GetAttributeByNum(TupleTableSlot *slot,
 	return (char *) retval;
 }
 
-#endif
-
 /* XXX char16 name for catalogs */
 #ifdef NOT_USED
 char	   *
diff --git a/src/include/executor/executor.h b/src/include/executor/executor.h
index 219984f17b8..08a5f4d3818 100644
--- a/src/include/executor/executor.h
+++ b/src/include/executor/executor.h
@@ -6,7 +6,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: executor.h,v 1.13 1997/09/08 21:51:51 momjian Exp $
+ * $Id: executor.h,v 1.14 1997/09/27 14:37:21 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -80,8 +80,9 @@ ExecEvalParam(Param *expression, ExprContext *econtext,
 
 /* stop here */
 extern char *
-GetAttributeByName(TupleTableSlot *slot, char *attname,
-				   bool *isNull);
+GetAttributeByNum(TupleTableSlot *slot, AttrNumber attrno, bool *isNull);
+extern char *
+GetAttributeByName(TupleTableSlot *slot, char *attname, bool *isNull);
 extern Datum
 ExecEvalExpr(Node *expression, ExprContext *econtext, bool *isNull,
 			 bool *isDone);
-- 
GitLab