mirror of
https://github.com/postgres/postgres.git
synced 2025-06-14 18:42:34 +03:00
Make functions static or NOT_USED as appropriate.
This commit is contained in:
@ -4,7 +4,7 @@
|
|||||||
# Makefile for access/common
|
# Makefile for access/common
|
||||||
#
|
#
|
||||||
# IDENTIFICATION
|
# IDENTIFICATION
|
||||||
# $Header: /cvsroot/pgsql/src/backend/access/common/Makefile,v 1.12 1998/07/26 04:30:16 scrappy Exp $
|
# $Header: /cvsroot/pgsql/src/backend/access/common/Makefile,v 1.13 1999/05/26 12:55:05 momjian Exp $
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
|
|
||||||
@ -17,7 +17,7 @@ ifdef MULTIBYTE
|
|||||||
CFLAGS+= $(MBFLAGS)
|
CFLAGS+= $(MBFLAGS)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
OBJS = heaptuple.o heapvalid.o indextuple.o indexvalid.o printtup.o \
|
OBJS = heaptuple.o indextuple.o indexvalid.o printtup.o \
|
||||||
scankey.o tupdesc.o
|
scankey.o tupdesc.o
|
||||||
|
|
||||||
all: SUBSYS.o
|
all: SUBSYS.o
|
||||||
|
@ -1,34 +0,0 @@
|
|||||||
/*-------------------------------------------------------------------------
|
|
||||||
*
|
|
||||||
* heapvalid.c
|
|
||||||
* heap tuple qualification validity checking code
|
|
||||||
*
|
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* IDENTIFICATION
|
|
||||||
* $Header: /cvsroot/pgsql/src/backend/access/common/Attic/heapvalid.c,v 1.23 1999/02/13 23:14:11 momjian Exp $
|
|
||||||
*
|
|
||||||
*-------------------------------------------------------------------------
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <postgres.h>
|
|
||||||
|
|
||||||
#include <access/valid.h>
|
|
||||||
#include <access/xact.h>
|
|
||||||
|
|
||||||
/*
|
|
||||||
* TupleUpdatedByCurXactAndCmd() -- Returns true if this tuple has
|
|
||||||
* already been updated once by the current transaction/command
|
|
||||||
* pair.
|
|
||||||
*/
|
|
||||||
bool
|
|
||||||
TupleUpdatedByCurXactAndCmd(HeapTuple t)
|
|
||||||
{
|
|
||||||
if (TransactionIdEquals(t->t_data->t_xmax,
|
|
||||||
GetCurrentTransactionId()) &&
|
|
||||||
CommandIdGEScanCommandId(t->t_data->t_cmax))
|
|
||||||
return true;
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.77 1999/05/25 16:08:19 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.78 1999/05/26 12:55:10 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -73,14 +73,14 @@ static int lineno;
|
|||||||
/*
|
/*
|
||||||
* Internal communications functions
|
* Internal communications functions
|
||||||
*/
|
*/
|
||||||
inline void CopySendData(void *databuf, int datasize, FILE *fp);
|
static void CopySendData(void *databuf, int datasize, FILE *fp);
|
||||||
inline void CopySendString(char *str, FILE *fp);
|
static void CopySendString(char *str, FILE *fp);
|
||||||
inline void CopySendChar(char c, FILE *fp);
|
static void CopySendChar(char c, FILE *fp);
|
||||||
inline void CopyGetData(void *databuf, int datasize, FILE *fp);
|
static void CopyGetData(void *databuf, int datasize, FILE *fp);
|
||||||
inline int CopyGetChar(FILE *fp);
|
static int CopyGetChar(FILE *fp);
|
||||||
inline int CopyGetEof(FILE *fp);
|
static int CopyGetEof(FILE *fp);
|
||||||
inline int CopyPeekChar(FILE *fp);
|
static int CopyPeekChar(FILE *fp);
|
||||||
inline void CopyDonePeek(FILE *fp, int c, int pickup);
|
static void CopyDonePeek(FILE *fp, int c, int pickup);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* CopySendData sends output data either to the file
|
* CopySendData sends output data either to the file
|
||||||
@ -92,7 +92,7 @@ inline void CopyDonePeek(FILE *fp, int c, int pickup);
|
|||||||
*
|
*
|
||||||
* NB: no data conversion is applied by these functions
|
* NB: no data conversion is applied by these functions
|
||||||
*/
|
*/
|
||||||
inline void
|
static void
|
||||||
CopySendData(void *databuf, int datasize, FILE *fp)
|
CopySendData(void *databuf, int datasize, FILE *fp)
|
||||||
{
|
{
|
||||||
if (!fp)
|
if (!fp)
|
||||||
@ -101,13 +101,13 @@ CopySendData(void *databuf, int datasize, FILE *fp)
|
|||||||
fwrite(databuf, datasize, 1, fp);
|
fwrite(databuf, datasize, 1, fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void
|
static void
|
||||||
CopySendString(char *str, FILE *fp)
|
CopySendString(char *str, FILE *fp)
|
||||||
{
|
{
|
||||||
CopySendData(str, strlen(str), fp);
|
CopySendData(str, strlen(str), fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void
|
static void
|
||||||
CopySendChar(char c, FILE *fp)
|
CopySendChar(char c, FILE *fp)
|
||||||
{
|
{
|
||||||
CopySendData(&c, 1, fp);
|
CopySendData(&c, 1, fp);
|
||||||
@ -123,7 +123,7 @@ CopySendChar(char c, FILE *fp)
|
|||||||
*
|
*
|
||||||
* NB: no data conversion is applied by these functions
|
* NB: no data conversion is applied by these functions
|
||||||
*/
|
*/
|
||||||
inline void
|
static void
|
||||||
CopyGetData(void *databuf, int datasize, FILE *fp)
|
CopyGetData(void *databuf, int datasize, FILE *fp)
|
||||||
{
|
{
|
||||||
if (!fp)
|
if (!fp)
|
||||||
@ -132,7 +132,7 @@ CopyGetData(void *databuf, int datasize, FILE *fp)
|
|||||||
fread(databuf, datasize, 1, fp);
|
fread(databuf, datasize, 1, fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int
|
static int
|
||||||
CopyGetChar(FILE *fp)
|
CopyGetChar(FILE *fp)
|
||||||
{
|
{
|
||||||
if (!fp)
|
if (!fp)
|
||||||
@ -147,7 +147,7 @@ CopyGetChar(FILE *fp)
|
|||||||
return getc(fp);
|
return getc(fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int
|
static int
|
||||||
CopyGetEof(FILE *fp)
|
CopyGetEof(FILE *fp)
|
||||||
{
|
{
|
||||||
if (!fp)
|
if (!fp)
|
||||||
@ -164,7 +164,7 @@ CopyGetEof(FILE *fp)
|
|||||||
* CopyDonePeek will either take the peeked char off the steam
|
* CopyDonePeek will either take the peeked char off the steam
|
||||||
* (if pickup is != 0) or leave it on the stream (if pickup == 0)
|
* (if pickup is != 0) or leave it on the stream (if pickup == 0)
|
||||||
*/
|
*/
|
||||||
inline int
|
static int
|
||||||
CopyPeekChar(FILE *fp)
|
CopyPeekChar(FILE *fp)
|
||||||
{
|
{
|
||||||
if (!fp)
|
if (!fp)
|
||||||
@ -173,7 +173,7 @@ CopyPeekChar(FILE *fp)
|
|||||||
return getc(fp);
|
return getc(fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void
|
static void
|
||||||
CopyDonePeek(FILE *fp, int c, int pickup)
|
CopyDonePeek(FILE *fp, int c, int pickup)
|
||||||
{
|
{
|
||||||
if (!fp)
|
if (!fp)
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: stringinfo.c,v 1.16 1999/05/25 16:08:53 momjian Exp $
|
* $Id: stringinfo.c,v 1.17 1999/05/26 12:55:14 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -19,6 +19,7 @@
|
|||||||
#include "postgres.h"
|
#include "postgres.h"
|
||||||
#include "lib/stringinfo.h"
|
#include "lib/stringinfo.h"
|
||||||
|
|
||||||
|
#ifdef NOT_USED
|
||||||
/*
|
/*
|
||||||
* makeStringInfo
|
* makeStringInfo
|
||||||
*
|
*
|
||||||
@ -37,6 +38,7 @@ makeStringInfo(void)
|
|||||||
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* initStringInfo
|
* initStringInfo
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/libpq/auth.c,v 1.36 1999/05/25 16:08:55 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/libpq/auth.c,v 1.37 1999/05/26 12:55:15 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -50,6 +50,7 @@ static int pg_passwordv0_recvauth(void *arg, PacketLen len, void *pkt);
|
|||||||
static int checkPassword(Port *port, char *user, char *password);
|
static int checkPassword(Port *port, char *user, char *password);
|
||||||
static int old_be_recvauth(Port *port);
|
static int old_be_recvauth(Port *port);
|
||||||
static int map_old_to_new(Port *port, UserAuth old, int status);
|
static int map_old_to_new(Port *port, UserAuth old, int status);
|
||||||
|
static void auth_failed(Port *port);
|
||||||
|
|
||||||
|
|
||||||
#ifdef KRB4
|
#ifdef KRB4
|
||||||
@ -402,7 +403,7 @@ pg_passwordv0_recvauth(void *arg, PacketLen len, void *pkt)
|
|||||||
* postmaster log, which we hope is only readable by good guys.
|
* postmaster log, which we hope is only readable by good guys.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void
|
static void
|
||||||
auth_failed(Port *port)
|
auth_failed(Port *port)
|
||||||
{
|
{
|
||||||
char buffer[512];
|
char buffer[512];
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/nodes/Attic/freefuncs.c,v 1.18 1999/05/25 22:41:13 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/nodes/Attic/freefuncs.c,v 1.19 1999/05/26 12:55:20 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -35,6 +35,7 @@
|
|||||||
* plannodes.h free functions
|
* plannodes.h free functions
|
||||||
* ****************************************************************
|
* ****************************************************************
|
||||||
*/
|
*/
|
||||||
|
static void freeObject(void *obj);
|
||||||
|
|
||||||
/* ----------------
|
/* ----------------
|
||||||
* FreePlanFields
|
* FreePlanFields
|
||||||
@ -1157,7 +1158,7 @@ _freeValue(Value *node)
|
|||||||
* recursively frees its items.
|
* recursively frees its items.
|
||||||
* ----------------
|
* ----------------
|
||||||
*/
|
*/
|
||||||
void
|
static void
|
||||||
freeObject(void *node)
|
freeObject(void *node)
|
||||||
{
|
{
|
||||||
if (node == NULL)
|
if (node == NULL)
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/joinrels.c,v 1.34 1999/05/25 22:41:31 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/optimizer/path/joinrels.c,v 1.35 1999/05/26 12:55:27 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -28,6 +28,9 @@ static bool nonoverlap_sets(List *s1, List *s2);
|
|||||||
static bool is_subset(List *s1, List *s2);
|
static bool is_subset(List *s1, List *s2);
|
||||||
static void set_joinrel_size(RelOptInfo *joinrel, RelOptInfo *outer_rel,
|
static void set_joinrel_size(RelOptInfo *joinrel, RelOptInfo *outer_rel,
|
||||||
RelOptInfo *inner_rel, JoinInfo *jinfo);
|
RelOptInfo *inner_rel, JoinInfo *jinfo);
|
||||||
|
static RelOptInfo *make_join_rel(RelOptInfo *outer_rel, RelOptInfo *inner_rel,
|
||||||
|
JoinInfo *joininfo);
|
||||||
|
static List *new_join_tlist(List *tlist, int first_resdomno);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* make_rels_by_joins
|
* make_rels_by_joins
|
||||||
@ -191,7 +194,7 @@ make_rels_by_clauseless_joins(RelOptInfo *old_rel, List *inner_rels)
|
|||||||
*
|
*
|
||||||
* Returns the new join relation node.
|
* Returns the new join relation node.
|
||||||
*/
|
*/
|
||||||
RelOptInfo *
|
static RelOptInfo *
|
||||||
make_join_rel(RelOptInfo *outer_rel, RelOptInfo *inner_rel, JoinInfo *joininfo)
|
make_join_rel(RelOptInfo *outer_rel, RelOptInfo *inner_rel, JoinInfo *joininfo)
|
||||||
{
|
{
|
||||||
RelOptInfo *joinrel = makeNode(RelOptInfo);
|
RelOptInfo *joinrel = makeNode(RelOptInfo);
|
||||||
@ -265,7 +268,7 @@ make_join_rel(RelOptInfo *outer_rel, RelOptInfo *inner_rel, JoinInfo *joininfo)
|
|||||||
*
|
*
|
||||||
* Returns the new target list.
|
* Returns the new target list.
|
||||||
*/
|
*/
|
||||||
List *
|
static List *
|
||||||
new_join_tlist(List *tlist,
|
new_join_tlist(List *tlist,
|
||||||
int first_resdomno)
|
int first_resdomno)
|
||||||
{
|
{
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.48 1999/05/25 22:41:41 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/setrefs.c,v 1.49 1999/05/26 12:55:28 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -47,6 +47,9 @@ static bool OperandIsInner(Node *opnd, int inner_relid);
|
|||||||
static List *pull_agg_clause(Node *clause);
|
static List *pull_agg_clause(Node *clause);
|
||||||
static Node *del_agg_clause(Node *clause);
|
static Node *del_agg_clause(Node *clause);
|
||||||
static void set_result_tlist_references(Result *resultNode);
|
static void set_result_tlist_references(Result *resultNode);
|
||||||
|
static void replace_vars_with_subplan_refs(Node *clause,
|
||||||
|
Index subvarno,
|
||||||
|
List *subplanTargetList);
|
||||||
|
|
||||||
/*****************************************************************************
|
/*****************************************************************************
|
||||||
*
|
*
|
||||||
@ -603,7 +606,7 @@ replace_tlist_with_subplan_refs(List *tlist,
|
|||||||
* Afterwards, all Var nodes have varno = subvarno, varattno = resno
|
* Afterwards, all Var nodes have varno = subvarno, varattno = resno
|
||||||
* of corresponding subplan target.
|
* of corresponding subplan target.
|
||||||
*/
|
*/
|
||||||
void
|
static void
|
||||||
replace_vars_with_subplan_refs(Node *clause,
|
replace_vars_with_subplan_refs(Node *clause,
|
||||||
Index subvarno,
|
Index subvarno,
|
||||||
List *subplanTargetList)
|
List *subplanTargetList)
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/parser/parse_clause.c,v 1.36 1999/05/25 16:10:14 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/parser/parse_clause.c,v 1.37 1999/05/26 12:55:35 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -41,14 +41,12 @@ static TargetEntry *
|
|||||||
|
|
||||||
static void parseFromClause(ParseState *pstate, List *frmList, Node **qual);
|
static void parseFromClause(ParseState *pstate, List *frmList, Node **qual);
|
||||||
|
|
||||||
Attr *makeAttr(char *relname, char *attname);
|
|
||||||
|
|
||||||
#ifdef ENABLE_OUTER_JOINS
|
#ifdef ENABLE_OUTER_JOINS
|
||||||
Node *transformUsingClause(ParseState *pstate, List *onList, char *lname, char *rname);
|
Node *transformUsingClause(ParseState *pstate, List *onList, char *lname, char *rname);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
char *transformTableEntry(ParseState *pstate, RangeVar *r);
|
static char *transformTableEntry(ParseState *pstate, RangeVar *r);
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -126,7 +124,8 @@ transformWhereClause(ParseState *pstate, Node *a_expr, Node *o_expr)
|
|||||||
return qual;
|
return qual;
|
||||||
}
|
}
|
||||||
|
|
||||||
Attr *
|
#ifdef NOT_USED
|
||||||
|
static Attr *
|
||||||
makeAttr(char *relname, char *attname)
|
makeAttr(char *relname, char *attname)
|
||||||
{
|
{
|
||||||
Attr *a = makeNode(Attr);
|
Attr *a = makeNode(Attr);
|
||||||
@ -138,6 +137,7 @@ makeAttr(char *relname, char *attname)
|
|||||||
|
|
||||||
return a;
|
return a;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef ENABLE_OUTER_JOINS
|
#ifdef ENABLE_OUTER_JOINS
|
||||||
/* transformUsingClause()
|
/* transformUsingClause()
|
||||||
@ -206,7 +206,7 @@ transformUsingClause(ParseState *pstate, List *onList, char *lname, char *rname)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
char *
|
static char *
|
||||||
transformTableEntry(ParseState *pstate, RangeVar *r)
|
transformTableEntry(ParseState *pstate, RangeVar *r)
|
||||||
{
|
{
|
||||||
RelExpr *baserel = r->relExpr;
|
RelExpr *baserel = r->relExpr;
|
||||||
@ -744,7 +744,8 @@ transformSortClause(ParseState *pstate,
|
|||||||
* Let's just try matching in pairs for now (right to left) and see if it works.
|
* Let's just try matching in pairs for now (right to left) and see if it works.
|
||||||
* - thomas 1998-05-22
|
* - thomas 1998-05-22
|
||||||
*/
|
*/
|
||||||
List *
|
#ifdef NOT_USED
|
||||||
|
static List *
|
||||||
transformUnionClause(List *unionClause, List *targetlist)
|
transformUnionClause(List *unionClause, List *targetlist)
|
||||||
{
|
{
|
||||||
List *union_list = NIL;
|
List *union_list = NIL;
|
||||||
@ -832,4 +833,5 @@ transformUnionClause(List *unionClause, List *targetlist)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
return NIL;
|
return NIL;
|
||||||
} /* transformUnionClause() */
|
}
|
||||||
|
#endif
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/parser/parse_expr.c,v 1.48 1999/05/25 16:10:16 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/parser/parse_expr.c,v 1.49 1999/05/26 12:55:37 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -33,6 +33,7 @@
|
|||||||
#include "utils/builtins.h"
|
#include "utils/builtins.h"
|
||||||
|
|
||||||
static Node *parser_typecast(Value *expr, TypeName *typename, int32 atttypmod);
|
static Node *parser_typecast(Value *expr, TypeName *typename, int32 atttypmod);
|
||||||
|
static Node *transformIdent(ParseState *pstate, Node *expr, int precedence);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* transformExpr -
|
* transformExpr -
|
||||||
@ -534,7 +535,7 @@ transformExpr(ParseState *pstate, Node *expr, int precedence)
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
Node *
|
static Node *
|
||||||
transformIdent(ParseState *pstate, Node *expr, int precedence)
|
transformIdent(ParseState *pstate, Node *expr, int precedence)
|
||||||
{
|
{
|
||||||
Ident *ident = (Ident *) expr;
|
Ident *ident = (Ident *) expr;
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.45 1999/05/25 16:10:50 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.46 1999/05/26 12:55:46 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -61,7 +61,12 @@ static SubLink *modifyAggrefMakeSublink(Expr *origexp, Query *parsetree);
|
|||||||
static void modifyAggrefQual(Node **nodePtr, Query *parsetree);
|
static void modifyAggrefQual(Node **nodePtr, Query *parsetree);
|
||||||
static bool checkQueryHasAggs(Node *node);
|
static bool checkQueryHasAggs(Node *node);
|
||||||
static Query *fireRIRrules(Query *parsetree);
|
static Query *fireRIRrules(Query *parsetree);
|
||||||
|
static Query *Except_Intersect_Rewrite(Query *parsetree);
|
||||||
|
static void check_targetlists_are_compatible(List *prev_target,
|
||||||
|
List *current_target);
|
||||||
|
static void create_intersect_list(Node *ptr, List **intersect_list);
|
||||||
|
static Node *intersect_tree_analyze(Node *tree, Node *first_select,
|
||||||
|
Node *parsetree);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* gatherRewriteMeta -
|
* gatherRewriteMeta -
|
||||||
@ -2934,7 +2939,7 @@ QueryRewrite(Query *parsetree)
|
|||||||
/* This function takes two targetlists as arguments and checks if the
|
/* This function takes two targetlists as arguments and checks if the
|
||||||
* targetlists are compatible (i.e. both select for the same number of
|
* targetlists are compatible (i.e. both select for the same number of
|
||||||
* attributes and the types are compatible */
|
* attributes and the types are compatible */
|
||||||
void
|
static void
|
||||||
check_targetlists_are_compatible(List *prev_target, List *current_target)
|
check_targetlists_are_compatible(List *prev_target, List *current_target)
|
||||||
{
|
{
|
||||||
List *tl,
|
List *tl,
|
||||||
@ -3026,7 +3031,7 @@ check_targetlists_are_compatible(List *prev_target, List *current_target)
|
|||||||
* new top Node can differ from the parsetree given as argument because of
|
* new top Node can differ from the parsetree given as argument because of
|
||||||
* the translation to DNF. That's why we have to remember the sortClause or
|
* the translation to DNF. That's why we have to remember the sortClause or
|
||||||
* unique flag!) */
|
* unique flag!) */
|
||||||
Query *
|
static Query *
|
||||||
Except_Intersect_Rewrite(Query *parsetree)
|
Except_Intersect_Rewrite(Query *parsetree)
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -3153,7 +3158,7 @@ Except_Intersect_Rewrite(Query *parsetree)
|
|||||||
* returned
|
* returned
|
||||||
*/
|
*/
|
||||||
intersect_list = NIL;
|
intersect_list = NIL;
|
||||||
create_list((Node *) lfirst(intersect), &intersect_list);
|
create_intersect_list((Node *) lfirst(intersect), &intersect_list);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This one will become the Select Query node, all other nodes are
|
* This one will become the Select Query node, all other nodes are
|
||||||
@ -3314,8 +3319,8 @@ Except_Intersect_Rewrite(Query *parsetree)
|
|||||||
* least one non negated Query node. This node is attached to the
|
* least one non negated Query node. This node is attached to the
|
||||||
* beginning of the list */
|
* beginning of the list */
|
||||||
|
|
||||||
void
|
static void
|
||||||
create_list(Node *ptr, List **intersect_list)
|
create_intersect_list(Node *ptr, List **intersect_list)
|
||||||
{
|
{
|
||||||
List *arg;
|
List *arg;
|
||||||
|
|
||||||
@ -3337,7 +3342,7 @@ create_list(Node *ptr, List **intersect_list)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
foreach(arg, ((Expr *) ptr)->args)
|
foreach(arg, ((Expr *) ptr)->args)
|
||||||
create_list(lfirst(arg), intersect_list);
|
create_intersect_list(lfirst(arg), intersect_list);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
@ -3348,7 +3353,7 @@ create_list(Node *ptr, List **intersect_list)
|
|||||||
* The node given in first_select has already been cooked, so don't transform
|
* The node given in first_select has already been cooked, so don't transform
|
||||||
* it again but return a pointer to the previously cooked version given in 'parsetree'
|
* it again but return a pointer to the previously cooked version given in 'parsetree'
|
||||||
* instead. */
|
* instead. */
|
||||||
Node *
|
static Node *
|
||||||
intersect_tree_analyze(Node *tree, Node *first_select, Node *parsetree)
|
intersect_tree_analyze(Node *tree, Node *first_select, Node *parsetree)
|
||||||
{
|
{
|
||||||
Node *result = (Node *) NIL;
|
Node *result = (Node *) NIL;
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteManip.c,v 1.31 1999/05/25 16:10:52 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteManip.c,v 1.32 1999/05/26 12:55:48 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -516,6 +516,7 @@ AddHavingQual(Query *parsetree, Node *havingQual)
|
|||||||
parsetree->havingQual = (Node *) make_andclause(makeList(parsetree->havingQual, copy, -1));
|
parsetree->havingQual = (Node *) make_andclause(makeList(parsetree->havingQual, copy, -1));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef NOT_USED
|
||||||
void
|
void
|
||||||
AddNotHavingQual(Query *parsetree, Node *havingQual)
|
AddNotHavingQual(Query *parsetree, Node *havingQual)
|
||||||
{
|
{
|
||||||
@ -531,6 +532,7 @@ AddNotHavingQual(Query *parsetree, Node *havingQual)
|
|||||||
|
|
||||||
AddHavingQual(parsetree, copy);
|
AddHavingQual(parsetree, copy);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
void
|
void
|
||||||
AddNotQual(Query *parsetree, Node *qual)
|
AddNotQual(Query *parsetree, Node *qual)
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Id: fd.c,v 1.41 1999/05/25 22:41:57 momjian Exp $
|
* $Id: fd.c,v 1.42 1999/05/26 12:55:51 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES:
|
* NOTES:
|
||||||
*
|
*
|
||||||
@ -191,6 +191,7 @@ static int FileAccess(File file);
|
|||||||
static File fileNameOpenFile(FileName fileName, int fileFlags, int fileMode);
|
static File fileNameOpenFile(FileName fileName, int fileFlags, int fileMode);
|
||||||
static char *filepath(char *filename);
|
static char *filepath(char *filename);
|
||||||
static long pg_nofile(void);
|
static long pg_nofile(void);
|
||||||
|
static int BufFileFlush(BufFile *file);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* pg_fsync --- same as fsync except does nothing if -F switch was given
|
* pg_fsync --- same as fsync except does nothing if -F switch was given
|
||||||
@ -1168,7 +1169,7 @@ BufFileWrite(BufFile *file, void *ptr, size_t size)
|
|||||||
*
|
*
|
||||||
* Like fflush()
|
* Like fflush()
|
||||||
*/
|
*/
|
||||||
int
|
static int
|
||||||
BufFileFlush(BufFile *file)
|
BufFileFlush(BufFile *file)
|
||||||
{
|
{
|
||||||
if (file->dirty)
|
if (file->dirty)
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.116 1999/05/25 16:11:40 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.117 1999/05/26 12:55:55 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* this is the "main" module of the postgres backend and
|
* this is the "main" module of the postgres backend and
|
||||||
@ -190,6 +190,7 @@ int _exec_repeat_ = 1;
|
|||||||
static char InteractiveBackend(char *inBuf);
|
static char InteractiveBackend(char *inBuf);
|
||||||
static char SocketBackend(char *inBuf);
|
static char SocketBackend(char *inBuf);
|
||||||
static char ReadCommand(char *inBuf);
|
static char ReadCommand(char *inBuf);
|
||||||
|
static void pg_exec_query(char *query_string);
|
||||||
|
|
||||||
|
|
||||||
/* ----------------------------------------------------------------
|
/* ----------------------------------------------------------------
|
||||||
@ -647,7 +648,7 @@ pg_parse_and_plan(char *query_string, /* string to execute */
|
|||||||
* ----------------------------------------------------------------
|
* ----------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void
|
static void
|
||||||
pg_exec_query(char *query_string)
|
pg_exec_query(char *query_string)
|
||||||
{
|
{
|
||||||
pg_exec_query_dest(query_string, whereToSendOutput, FALSE);
|
pg_exec_query_dest(query_string, whereToSendOutput, FALSE);
|
||||||
@ -1526,7 +1527,7 @@ PostgresMain(int argc, char *argv[], int real_argc, char *real_argv[])
|
|||||||
if (!IsUnderPostmaster)
|
if (!IsUnderPostmaster)
|
||||||
{
|
{
|
||||||
puts("\nPOSTGRES backend interactive interface ");
|
puts("\nPOSTGRES backend interactive interface ");
|
||||||
puts("$Revision: 1.116 $ $Date: 1999/05/25 16:11:40 $\n");
|
puts("$Revision: 1.117 $ $Date: 1999/05/26 12:55:55 $\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ----------------
|
/* ----------------
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* Edmund Mergl <E.Mergl@bawue.de>
|
* Edmund Mergl <E.Mergl@bawue.de>
|
||||||
*
|
*
|
||||||
* $Id: oracle_compat.c,v 1.17 1999/02/21 03:49:32 scrappy Exp $
|
* $Id: oracle_compat.c,v 1.18 1999/05/26 12:56:00 momjian Exp $
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@ -472,6 +472,7 @@ rtrim(text *string, text *set)
|
|||||||
*
|
*
|
||||||
********************************************************************/
|
********************************************************************/
|
||||||
|
|
||||||
|
#ifdef NOT_USED
|
||||||
text *
|
text *
|
||||||
substr(text *string, int4 m, int4 n)
|
substr(text *string, int4 m, int4 n)
|
||||||
{
|
{
|
||||||
@ -498,7 +499,7 @@ substr(text *string, int4 m, int4 n)
|
|||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/********************************************************************
|
/********************************************************************
|
||||||
*
|
*
|
||||||
|
@ -131,6 +131,7 @@ tprintf(int flag, const char *fmt,...)
|
|||||||
/*
|
/*
|
||||||
* Print a timestamp and a message to stdout or to syslog.
|
* Print a timestamp and a message to stdout or to syslog.
|
||||||
*/
|
*/
|
||||||
|
#ifdef NOT_USED
|
||||||
int
|
int
|
||||||
tprintf1(const char *fmt,...)
|
tprintf1(const char *fmt,...)
|
||||||
{
|
{
|
||||||
@ -156,6 +157,7 @@ tprintf1(const char *fmt,...)
|
|||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Print a timestamp and a message to stderr.
|
* Print a timestamp and a message to stderr.
|
||||||
@ -237,7 +239,8 @@ tprintf_timestamp()
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
int
|
#ifdef NOT_USED
|
||||||
|
static int
|
||||||
option_flag(int flag)
|
option_flag(int flag)
|
||||||
{
|
{
|
||||||
if ((flag < 0) || (flag >= NUM_PG_OPTIONS))
|
if ((flag < 0) || (flag >= NUM_PG_OPTIONS))
|
||||||
@ -254,6 +257,7 @@ set_option_flag(int flag, int value)
|
|||||||
pg_options[flag] = value;
|
pg_options[flag] = value;
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Parse an option string like "name,name+,name-,name=value".
|
* Parse an option string like "name,name+,name-,name=value".
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/utils/mmgr/Attic/oset.c,v 1.12 1999/05/25 16:12:54 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/utils/mmgr/Attic/oset.c,v 1.13 1999/05/26 12:56:05 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTE
|
* NOTE
|
||||||
* XXX This is a preliminary implementation which lacks fail-fast
|
* XXX This is a preliminary implementation which lacks fail-fast
|
||||||
@ -52,11 +52,13 @@ OrderedSetInit(OrderedSet set, Offset offset)
|
|||||||
* OrderedSetContains
|
* OrderedSetContains
|
||||||
* True iff ordered set contains given element.
|
* True iff ordered set contains given element.
|
||||||
*/
|
*/
|
||||||
|
#ifdef NOT_USED
|
||||||
bool
|
bool
|
||||||
OrderedSetContains(OrderedSet set, OrderedElem elem)
|
OrderedSetContains(OrderedSet set, OrderedElem elem)
|
||||||
{
|
{
|
||||||
return (bool) (elem->set == set && (elem->next || elem->prev));
|
return (bool) (elem->set == set && (elem->next || elem->prev));
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* OrderedSetGetHead
|
* OrderedSetGetHead
|
||||||
|
@ -27,15 +27,14 @@ extern char *crypt(const char *, const char *);
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
char *comname;
|
char *comname;
|
||||||
void usage(FILE *stream);
|
static void usage(FILE *stream);
|
||||||
void read_pwd_file(char *filename);
|
static void read_pwd_file(char *filename);
|
||||||
void write_pwd_file(char *filename, char *bkname);
|
static void write_pwd_file(char *filename, char *bkname);
|
||||||
void encrypt_pwd(char key[9], char salt[3], char passwd[14]);
|
static void encrypt_pwd(char key[9], char salt[3], char passwd[14]);
|
||||||
int check_pwd(char key[9], char passwd[14]);
|
static void prompt_for_username(char *username);
|
||||||
void prompt_for_username(char *username);
|
static void prompt_for_password(char *prompt, char *password);
|
||||||
void prompt_for_password(char *prompt, char *password);
|
|
||||||
|
|
||||||
void
|
static void
|
||||||
usage(FILE *stream)
|
usage(FILE *stream)
|
||||||
{
|
{
|
||||||
fprintf(stream, "Usage: %s <password file>\n", comname);
|
fprintf(stream, "Usage: %s <password file>\n", comname);
|
||||||
@ -54,7 +53,7 @@ pg_pwd pwds[MAXPWDS];
|
|||||||
int npwds = 0;
|
int npwds = 0;
|
||||||
|
|
||||||
|
|
||||||
void
|
static void
|
||||||
read_pwd_file(char *filename)
|
read_pwd_file(char *filename)
|
||||||
{
|
{
|
||||||
FILE *fp;
|
FILE *fp;
|
||||||
@ -176,7 +175,7 @@ try_again:
|
|||||||
fclose(fp);
|
fclose(fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
static void
|
||||||
write_pwd_file(char *filename, char *bkname)
|
write_pwd_file(char *filename, char *bkname)
|
||||||
{
|
{
|
||||||
FILE *fp;
|
FILE *fp;
|
||||||
@ -222,7 +221,7 @@ link_again:
|
|||||||
fclose(fp);
|
fclose(fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
static void
|
||||||
encrypt_pwd(char key[9], char salt[3], char passwd[14])
|
encrypt_pwd(char key[9], char salt[3], char passwd[14])
|
||||||
{
|
{
|
||||||
int n;
|
int n;
|
||||||
@ -253,7 +252,8 @@ encrypt_pwd(char key[9], char salt[3], char passwd[14])
|
|||||||
*/
|
*/
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
#ifdef NOT_USED
|
||||||
|
static int
|
||||||
check_pwd(char key[9], char passwd[14])
|
check_pwd(char key[9], char passwd[14])
|
||||||
{
|
{
|
||||||
char shouldbe[14];
|
char shouldbe[14];
|
||||||
@ -266,8 +266,9 @@ check_pwd(char key[9], char passwd[14])
|
|||||||
|
|
||||||
return strncmp(shouldbe, passwd, 13) == 0 ? 1 : 0;
|
return strncmp(shouldbe, passwd, 13) == 0 ? 1 : 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
void
|
static void
|
||||||
prompt_for_username(char *username)
|
prompt_for_username(char *username)
|
||||||
{
|
{
|
||||||
int length;
|
int length;
|
||||||
@ -290,7 +291,7 @@ prompt_for_username(char *username)
|
|||||||
username[length - 1] = '\0';
|
username[length - 1] = '\0';
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
static void
|
||||||
prompt_for_password(char *prompt, char *password)
|
prompt_for_password(char *prompt, char *password)
|
||||||
{
|
{
|
||||||
int length;
|
int length;
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: valid.h,v 1.17 1999/02/13 23:20:59 momjian Exp $
|
* $Id: valid.h,v 1.18 1999/05/26 12:56:15 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -146,6 +146,4 @@ do \
|
|||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
extern bool TupleUpdatedByCurXactAndCmd(HeapTuple t);
|
|
||||||
|
|
||||||
#endif /* VALID_H */
|
#endif /* VALID_H */
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: stringinfo.h,v 1.12 1999/05/25 16:13:59 momjian Exp $
|
* $Id: stringinfo.h,v 1.13 1999/05/26 12:56:27 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -60,11 +60,13 @@ typedef StringInfoData *StringInfo;
|
|||||||
*-------------------------
|
*-------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifdef NOT_USED
|
||||||
/*------------------------
|
/*------------------------
|
||||||
* makeStringInfo
|
* makeStringInfo
|
||||||
* Create an empty 'StringInfoData' & return a pointer to it.
|
* Create an empty 'StringInfoData' & return a pointer to it.
|
||||||
*/
|
*/
|
||||||
extern StringInfo makeStringInfo(void);
|
extern StringInfo makeStringInfo(void);
|
||||||
|
#endif
|
||||||
|
|
||||||
/*------------------------
|
/*------------------------
|
||||||
* initStringInfo
|
* initStringInfo
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: auth.h,v 1.11 1999/02/13 23:21:33 momjian Exp $
|
* $Id: auth.h,v 1.12 1999/05/26 12:56:29 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -21,7 +21,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
void be_recvauth(Port *port);
|
void be_recvauth(Port *port);
|
||||||
void auth_failed(Port *port);
|
|
||||||
|
|
||||||
#define PG_KRB4_VERSION "PGVER4.1" /* at most KRB_SENDAUTH_VLEN chars */
|
#define PG_KRB4_VERSION "PGVER4.1" /* at most KRB_SENDAUTH_VLEN chars */
|
||||||
#define PG_KRB5_VERSION "PGVER5.1"
|
#define PG_KRB5_VERSION "PGVER5.1"
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: nodes.h,v 1.48 1999/03/23 16:51:03 momjian Exp $
|
* $Id: nodes.h,v 1.49 1999/05/26 12:56:33 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -280,11 +280,6 @@ extern void *stringToNode(char *str);
|
|||||||
*/
|
*/
|
||||||
extern void *copyObject(void *obj);
|
extern void *copyObject(void *obj);
|
||||||
|
|
||||||
/*
|
|
||||||
* nodes/freefuncs.c
|
|
||||||
*/
|
|
||||||
extern void freeObject(void *obj);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* nodes/equalfuncs.c
|
* nodes/equalfuncs.c
|
||||||
*/
|
*/
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: paths.h,v 1.29 1999/05/25 22:43:11 momjian Exp $
|
* $Id: paths.h,v 1.30 1999/05/26 12:56:35 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -83,8 +83,6 @@ extern List *make_rels_by_clause_joins(Query *root, RelOptInfo *old_rel,
|
|||||||
List *joininfo_list, Relids only_relids);
|
List *joininfo_list, Relids only_relids);
|
||||||
extern List *make_rels_by_clauseless_joins(RelOptInfo *old_rel,
|
extern List *make_rels_by_clauseless_joins(RelOptInfo *old_rel,
|
||||||
List *inner_rels);
|
List *inner_rels);
|
||||||
extern RelOptInfo *make_join_rel(RelOptInfo *outer_rel, RelOptInfo *inner_rel, JoinInfo *joininfo);
|
|
||||||
extern List *new_join_tlist(List *tlist, int first_resdomno);
|
|
||||||
extern RelOptInfo *get_cheapest_complete_rel(List *join_rel_list);
|
extern RelOptInfo *get_cheapest_complete_rel(List *join_rel_list);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: planmain.h,v 1.26 1999/05/25 16:14:22 momjian Exp $
|
* $Id: planmain.h,v 1.27 1999/05/26 12:56:36 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -57,9 +57,6 @@ extern List *index_outerjoin_references(List *inner_indxqual,
|
|||||||
extern void replace_tlist_with_subplan_refs(List *tlist,
|
extern void replace_tlist_with_subplan_refs(List *tlist,
|
||||||
Index subvarno,
|
Index subvarno,
|
||||||
List *subplanTargetList);
|
List *subplanTargetList);
|
||||||
extern void replace_vars_with_subplan_refs(Node *clause,
|
|
||||||
Index subvarno,
|
|
||||||
List *subplanTargetList);
|
|
||||||
extern bool set_agg_tlist_references(Agg *aggNode);
|
extern bool set_agg_tlist_references(Agg *aggNode);
|
||||||
extern void del_agg_tlist_references(List *tlist);
|
extern void del_agg_tlist_references(List *tlist);
|
||||||
extern void check_having_for_ungrouped_vars(Node *clause,
|
extern void check_having_for_ungrouped_vars(Node *clause,
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: parse_clause.h,v 1.8 1999/02/23 08:05:27 thomas Exp $
|
* $Id: parse_clause.h,v 1.9 1999/05/26 12:56:41 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -26,6 +26,4 @@ extern List *transformGroupClause(ParseState *pstate, List *grouplist,
|
|||||||
extern List *transformSortClause(ParseState *pstate,
|
extern List *transformSortClause(ParseState *pstate,
|
||||||
List *orderlist, List *sortClause,
|
List *orderlist, List *sortClause,
|
||||||
List *targetlist, char *uniqueFlag);
|
List *targetlist, char *uniqueFlag);
|
||||||
extern List *transformUnionClause(List *unionClause, List *targetlist);
|
|
||||||
|
|
||||||
#endif /* PARSE_CLAUSE_H */
|
#endif /* PARSE_CLAUSE_H */
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: parse_expr.h,v 1.10 1998/09/01 04:37:33 momjian Exp $
|
* $Id: parse_expr.h,v 1.11 1999/05/26 12:56:41 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -19,7 +19,6 @@
|
|||||||
#include <parser/parse_node.h>
|
#include <parser/parse_node.h>
|
||||||
|
|
||||||
extern Node *transformExpr(ParseState *pstate, Node *expr, int precedence);
|
extern Node *transformExpr(ParseState *pstate, Node *expr, int precedence);
|
||||||
extern Node *transformIdent(ParseState *pstate, Node *expr, int precedence);
|
|
||||||
extern Oid exprType(Node *expr);
|
extern Oid exprType(Node *expr);
|
||||||
extern Node *parser_typecast2(Node *expr, Oid exprType, Type tp, int32 attypmod);
|
extern Node *parser_typecast2(Node *expr, Oid exprType, Type tp, int32 attypmod);
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: rewriteHandler.h,v 1.9 1999/05/25 16:14:34 momjian Exp $
|
* $Id: rewriteHandler.h,v 1.10 1999/05/26 12:56:48 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -35,10 +35,5 @@ typedef struct _rewrite_meta_knowledge RewriteInfo;
|
|||||||
|
|
||||||
extern List *QueryRewrite(Query *parsetree);
|
extern List *QueryRewrite(Query *parsetree);
|
||||||
|
|
||||||
/***S*I***/
|
|
||||||
extern Query *Except_Intersect_Rewrite(Query *parsetree);
|
|
||||||
extern void create_list(Node *ptr, List **intersect_list);
|
|
||||||
extern Node *intersect_tree_analyze(Node *tree, Node *first_select, Node *parsetree);
|
|
||||||
extern void check_targetlists_are_compatible(List *prev_target, List *current_target);
|
|
||||||
|
|
||||||
#endif /* REWRITEHANDLER_H */
|
#endif /* REWRITEHANDLER_H */
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: rewriteManip.h,v 1.15 1999/05/25 16:14:35 momjian Exp $
|
* $Id: rewriteManip.h,v 1.16 1999/05/26 12:56:50 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -25,7 +25,6 @@ void AddQual(Query *parsetree, Node *qual);
|
|||||||
void AddHavingQual(Query *parsetree, Node *havingQual);
|
void AddHavingQual(Query *parsetree, Node *havingQual);
|
||||||
|
|
||||||
void AddNotQual(Query *parsetree, Node *qual);
|
void AddNotQual(Query *parsetree, Node *qual);
|
||||||
void AddNotHavingQual(Query *parsetree, Node *havingQual);
|
|
||||||
void AddGroupClause(Query *parsetree, List *group_by, List *tlist);
|
void AddGroupClause(Query *parsetree, List *group_by, List *tlist);
|
||||||
|
|
||||||
void FixNew(RewriteInfo *info, Query *parsetree);
|
void FixNew(RewriteInfo *info, Query *parsetree);
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: fd.h,v 1.15 1999/05/25 22:43:24 momjian Exp $
|
* $Id: fd.h,v 1.16 1999/05/26 12:56:53 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -94,7 +94,6 @@ extern BufFile *BufFileCreate(File file);
|
|||||||
extern void BufFileClose(BufFile *file);
|
extern void BufFileClose(BufFile *file);
|
||||||
extern size_t BufFileRead(BufFile *file, void *ptr, size_t size);
|
extern size_t BufFileRead(BufFile *file, void *ptr, size_t size);
|
||||||
extern size_t BufFileWrite(BufFile *file, void *ptr, size_t size);
|
extern size_t BufFileWrite(BufFile *file, void *ptr, size_t size);
|
||||||
extern int BufFileFlush(BufFile *file);
|
|
||||||
extern long BufFileSeek(BufFile *file, long offset, int whence);
|
extern long BufFileSeek(BufFile *file, long offset, int whence);
|
||||||
|
|
||||||
/* Miscellaneous support routines */
|
/* Miscellaneous support routines */
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: tcopprot.h,v 1.20 1999/05/25 16:14:48 momjian Exp $
|
* $Id: tcopprot.h,v 1.21 1999/05/26 12:56:58 momjian Exp $
|
||||||
*
|
*
|
||||||
* OLD COMMENTS
|
* OLD COMMENTS
|
||||||
* This file was created so that other c files could get the two
|
* This file was created so that other c files could get the two
|
||||||
@ -43,7 +43,6 @@ extern bool InError;
|
|||||||
extern List *pg_parse_and_plan(char *query_string, Oid *typev, int nargs,
|
extern List *pg_parse_and_plan(char *query_string, Oid *typev, int nargs,
|
||||||
List **queryListP, CommandDest dest,
|
List **queryListP, CommandDest dest,
|
||||||
bool aclOverride);
|
bool aclOverride);
|
||||||
extern void pg_exec_query(char *query_string);
|
|
||||||
extern void pg_exec_query_acl_override(char *query_string);
|
extern void pg_exec_query_acl_override(char *query_string);
|
||||||
extern void
|
extern void
|
||||||
pg_exec_query_dest(char *query_string, CommandDest dest, bool aclOverride);
|
pg_exec_query_dest(char *query_string, CommandDest dest, bool aclOverride);
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: builtins.h,v 1.80 1999/05/25 22:43:31 momjian Exp $
|
* $Id: builtins.h,v 1.81 1999/05/26 12:57:03 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* This should normally only be included by fmgr.h.
|
* This should normally only be included by fmgr.h.
|
||||||
@ -518,7 +518,6 @@ extern text *lpad(text *string1, int4 len, text *string2);
|
|||||||
extern text *rpad(text *string1, int4 len, text *string2);
|
extern text *rpad(text *string1, int4 len, text *string2);
|
||||||
extern text *ltrim(text *string, text *set);
|
extern text *ltrim(text *string, text *set);
|
||||||
extern text *rtrim(text *string, text *set);
|
extern text *rtrim(text *string, text *set);
|
||||||
extern text *substr(text *string, int4 m, int4 n);
|
|
||||||
extern text *translate(text *string, char from, char to);
|
extern text *translate(text *string, char from, char to);
|
||||||
|
|
||||||
/* acl.c */
|
/* acl.c */
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: memutils.h,v 1.26 1999/05/25 22:43:36 momjian Exp $
|
* $Id: memutils.h,v 1.27 1999/05/26 12:57:07 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* some of the information in this file will be moved to
|
* some of the information in this file will be moved to
|
||||||
@ -80,7 +80,6 @@ struct OrderedSetData
|
|||||||
};
|
};
|
||||||
|
|
||||||
extern void OrderedSetInit(OrderedSet set, Offset offset);
|
extern void OrderedSetInit(OrderedSet set, Offset offset);
|
||||||
extern bool OrderedSetContains(OrderedSet set, OrderedElem elem);
|
|
||||||
extern Pointer OrderedSetGetHead(OrderedSet set);
|
extern Pointer OrderedSetGetHead(OrderedSet set);
|
||||||
extern Pointer OrderedElemGetPredecessor(OrderedElem elem);
|
extern Pointer OrderedElemGetPredecessor(OrderedElem elem);
|
||||||
extern Pointer OrderedElemGetSuccessor(OrderedElem elem);
|
extern Pointer OrderedElemGetSuccessor(OrderedElem elem);
|
||||||
|
@ -27,11 +27,8 @@ char *tprintf_timestamp(void);
|
|||||||
#define TIMESTAMP_SIZE 0
|
#define TIMESTAMP_SIZE 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern int tprintf1(const char *fmt,...);
|
|
||||||
extern int tprintf(int flag, const char *fmt,...);
|
extern int tprintf(int flag, const char *fmt,...);
|
||||||
extern int eprintf(const char *fmt,...);
|
extern int eprintf(const char *fmt,...);
|
||||||
extern int option_flag(int flag);
|
|
||||||
extern int set_option_flag(int flag, int value);
|
|
||||||
extern void write_syslog(int level, char *line);
|
extern void write_syslog(int level, char *line);
|
||||||
extern void parse_options(char *str, bool secure);
|
extern void parse_options(char *str, bool secure);
|
||||||
extern void read_pg_options(SIGNAL_ARGS);
|
extern void read_pg_options(SIGNAL_ARGS);
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
* procedural language (PL)
|
* procedural language (PL)
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/pl/tcl/pltcl.c,v 1.11 1999/05/25 22:43:51 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/pl/tcl/pltcl.c,v 1.12 1999/05/26 12:57:23 momjian Exp $
|
||||||
*
|
*
|
||||||
* This software is copyrighted by Jan Wieck - Hamburg.
|
* This software is copyrighted by Jan Wieck - Hamburg.
|
||||||
*
|
*
|
||||||
@ -114,7 +114,7 @@ static void pltcl_init_load_unknown(void);
|
|||||||
#endif /* PLTCL_UNKNOWN_SUPPORT */
|
#endif /* PLTCL_UNKNOWN_SUPPORT */
|
||||||
|
|
||||||
Datum pltcl_call_handler(FmgrInfo *proinfo,
|
Datum pltcl_call_handler(FmgrInfo *proinfo,
|
||||||
FmgrValues *proargs, bool *isNull);
|
FmgrValues *proargs, bool *isNull);
|
||||||
|
|
||||||
static Datum pltcl_func_handler(FmgrInfo *proinfo,
|
static Datum pltcl_func_handler(FmgrInfo *proinfo,
|
||||||
FmgrValues *proargs, bool *isNull);
|
FmgrValues *proargs, bool *isNull);
|
||||||
@ -367,6 +367,8 @@ pltcl_init_load_unknown(void)
|
|||||||
* call this function for execution of
|
* call this function for execution of
|
||||||
* PL/Tcl procedures.
|
* PL/Tcl procedures.
|
||||||
**********************************************************************/
|
**********************************************************************/
|
||||||
|
|
||||||
|
/* keep non-static */
|
||||||
Datum
|
Datum
|
||||||
pltcl_call_handler(FmgrInfo *proinfo,
|
pltcl_call_handler(FmgrInfo *proinfo,
|
||||||
FmgrValues *proargs,
|
FmgrValues *proargs,
|
||||||
@ -404,7 +406,6 @@ pltcl_call_handler(FmgrInfo *proinfo,
|
|||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**********************************************************************
|
/**********************************************************************
|
||||||
* pltcl_func_handler() - Handler for regular function calls
|
* pltcl_func_handler() - Handler for regular function calls
|
||||||
**********************************************************************/
|
**********************************************************************/
|
||||||
|
Reference in New Issue
Block a user