mirror of
https://github.com/postgres/postgres.git
synced 2025-10-25 13:17:41 +03:00
pg_type has a typnamespace column; system now supports creating types
in different namespaces. Also, cleanup work on relation namespace support: drop, alter, rename commands work for tables in non-default namespaces.
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: command.h,v 1.35 2002/03/26 19:16:40 tgl Exp $
|
||||
* $Id: command.h,v 1.36 2002/03/29 19:06:21 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -40,31 +40,27 @@ extern void PortalCleanup(Portal portal);
|
||||
/*
|
||||
* ALTER TABLE variants
|
||||
*/
|
||||
extern void AlterTableAddColumn(const char *relationName,
|
||||
bool inh, ColumnDef *colDef);
|
||||
extern void AlterTableAddColumn(Oid myrelid, bool inherits, ColumnDef *colDef);
|
||||
|
||||
extern void AlterTableAlterColumnDefault(const char *relationName,
|
||||
bool inh, const char *colName,
|
||||
Node *newDefault);
|
||||
extern void AlterTableAlterColumnDefault(Oid myrelid, bool inh,
|
||||
const char *colName, Node *newDefault);
|
||||
|
||||
extern void AlterTableAlterColumnFlags(const char *relationName,
|
||||
bool inh, const char *colName,
|
||||
Node *flagValue, const char *flagType);
|
||||
extern void AlterTableAlterColumnFlags(Oid myrelid,
|
||||
bool inh, const char *colName,
|
||||
Node *flagValue, const char *flagType);
|
||||
|
||||
extern void AlterTableDropColumn(const char *relationName,
|
||||
bool inh, const char *colName,
|
||||
int behavior);
|
||||
extern void AlterTableDropColumn(Oid myrelid, bool inh,
|
||||
const char *colName, int behavior);
|
||||
|
||||
extern void AlterTableAddConstraint(char *relationName,
|
||||
bool inh, List *newConstraints);
|
||||
extern void AlterTableAddConstraint(Oid myrelid,
|
||||
bool inh, List *newConstraints);
|
||||
|
||||
extern void AlterTableDropConstraint(const char *relationName,
|
||||
bool inh, const char *constrName,
|
||||
int behavior);
|
||||
extern void AlterTableDropConstraint(Oid myrelid,
|
||||
bool inh, const char *constrName, int behavior);
|
||||
|
||||
extern void AlterTableCreateToastTable(Oid relOid, bool silent);
|
||||
|
||||
extern void AlterTableOwner(const RangeVar *tgtrel, const char *newOwnerName);
|
||||
extern void AlterTableOwner(Oid relationOid, int32 newOwnerSysId);
|
||||
|
||||
/*
|
||||
* LOCK
|
||||
|
||||
@@ -7,16 +7,19 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: copy.h,v 1.16 2001/11/05 17:46:33 momjian Exp $
|
||||
* $Id: copy.h,v 1.17 2002/03/29 19:06:21 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef COPY_H
|
||||
#define COPY_H
|
||||
|
||||
#include "nodes/primnodes.h"
|
||||
|
||||
extern int copy_lineno;
|
||||
|
||||
void DoCopy(char *relname, bool binary, bool oids, bool from, bool pipe,
|
||||
char *filename, char *delim, char *null_print);
|
||||
void DoCopy(const RangeVar *relation, bool binary, bool oids,
|
||||
bool from, bool pipe,
|
||||
char *filename, char *delim, char *null_print);
|
||||
|
||||
#endif /* COPY_H */
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: creatinh.h,v 1.19 2002/03/22 02:56:36 tgl Exp $
|
||||
* $Id: creatinh.h,v 1.20 2002/03/29 19:06:22 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -17,7 +17,7 @@
|
||||
#include "nodes/parsenodes.h"
|
||||
|
||||
extern Oid DefineRelation(CreateStmt *stmt, char relkind);
|
||||
extern void RemoveRelation(const char *name);
|
||||
extern void TruncateRelation(const char *name);
|
||||
extern void RemoveRelation(const RangeVar *relation);
|
||||
extern void TruncateRelation(const RangeVar *relation);
|
||||
|
||||
#endif /* CREATINH_H */
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: defrem.h,v 1.32 2002/03/26 19:16:47 tgl Exp $
|
||||
* $Id: defrem.h,v 1.33 2002/03/29 19:06:22 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -36,19 +36,19 @@ extern void ReindexDatabase(const char *databaseName, bool force, bool all);
|
||||
* prototypes in define.c
|
||||
*/
|
||||
extern void CreateFunction(ProcedureStmt *stmt);
|
||||
extern void DefineOperator(char *name, List *parameters);
|
||||
extern void DefineAggregate(char *name, List *parameters);
|
||||
extern void DefineType(char *name, List *parameters);
|
||||
extern void DefineOperator(List *names, List *parameters);
|
||||
extern void DefineAggregate(List *names, List *parameters);
|
||||
extern void DefineType(List *names, List *parameters);
|
||||
extern void DefineDomain(CreateDomainStmt *stmt);
|
||||
|
||||
/*
|
||||
* prototypes in remove.c
|
||||
*/
|
||||
extern void RemoveDomain(char *domainName, int behavior);
|
||||
extern void RemoveDomain(List *names, int behavior);
|
||||
extern void RemoveFunction(char *functionName, List *argTypes);
|
||||
extern void RemoveOperator(char *operatorName,
|
||||
char *typeName1, char *typeName2);
|
||||
extern void RemoveType(char *typeName);
|
||||
extern void RemoveAggregate(char *aggName, char *aggType);
|
||||
TypeName *typeName1, TypeName *typeName2);
|
||||
extern void RemoveType(List *names);
|
||||
extern void RemoveAggregate(char *aggName, TypeName *aggType);
|
||||
|
||||
#endif /* DEFREM_H */
|
||||
|
||||
@@ -7,17 +7,17 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: rename.h,v 1.14 2002/03/26 19:16:49 tgl Exp $
|
||||
* $Id: rename.h,v 1.15 2002/03/29 19:06:22 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef RENAME_H
|
||||
#define RENAME_H
|
||||
|
||||
extern void renameatt(char *relname,
|
||||
extern void renameatt(Oid relid,
|
||||
char *oldattname,
|
||||
char *newattname,
|
||||
int recurse);
|
||||
bool recurse);
|
||||
|
||||
extern void renamerel(const RangeVar *relation,
|
||||
const char *newrelname);
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: view.h,v 1.13 2001/11/05 17:46:33 momjian Exp $
|
||||
* $Id: view.h,v 1.14 2002/03/29 19:06:22 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
#include "nodes/parsenodes.h"
|
||||
|
||||
extern void DefineView(char *view_name, Query *view_parse);
|
||||
extern void RemoveView(char *view_name);
|
||||
extern void DefineView(const RangeVar *view, Query *view_parse);
|
||||
extern void RemoveView(const RangeVar *view);
|
||||
|
||||
#endif /* VIEW_H */
|
||||
|
||||
Reference in New Issue
Block a user