mirror of
https://github.com/postgres/postgres.git
synced 2025-10-18 04:29:09 +03:00
Add more ALTER <object> .. SET SCHEMA commands.
This adds support for changing the schema of a conversion, operator, operator class, operator family, text search configuration, text search dictionary, text search parser, or text search template. Dimitri Fontaine, with assorted corrections and other kibitzing.
This commit is contained in:
@@ -6051,6 +6051,14 @@ AlterObjectSchemaStmt:
|
||||
n->newschema = $7;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER CONVERSION_P any_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_CONVERSION;
|
||||
n->object = $3;
|
||||
n->newschema = $6;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER DOMAIN_P any_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
@@ -6068,6 +6076,33 @@ AlterObjectSchemaStmt:
|
||||
n->newschema = $6;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER OPERATOR any_operator oper_argtypes SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_OPERATOR;
|
||||
n->object = $3;
|
||||
n->objarg = $4;
|
||||
n->newschema = $7;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER OPERATOR CLASS any_name USING access_method SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_OPCLASS;
|
||||
n->object = $4;
|
||||
n->objarg = list_make1($6);
|
||||
n->newschema = $9;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER OPERATOR FAMILY any_name USING access_method SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_OPFAMILY;
|
||||
n->object = $4;
|
||||
n->objarg = list_make1($6);
|
||||
n->newschema = $9;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER TABLE relation_expr SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
@@ -6076,6 +6111,38 @@ AlterObjectSchemaStmt:
|
||||
n->newschema = $6;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER TEXT_P SEARCH PARSER any_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_TSPARSER;
|
||||
n->object = $5;
|
||||
n->newschema = $8;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER TEXT_P SEARCH DICTIONARY any_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_TSDICTIONARY;
|
||||
n->object = $5;
|
||||
n->newschema = $8;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER TEXT_P SEARCH TEMPLATE any_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_TSTEMPLATE;
|
||||
n->object = $5;
|
||||
n->newschema = $8;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER TEXT_P SEARCH CONFIGURATION any_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
n->objectType = OBJECT_TSCONFIGURATION;
|
||||
n->object = $5;
|
||||
n->newschema = $8;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER SEQUENCE qualified_name SET SCHEMA name
|
||||
{
|
||||
AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt);
|
||||
|
Reference in New Issue
Block a user