Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6bdf4b9

Browse files
committed
Fix REASSIGN OWNED for text search objects
Trying to reassign objects owned by a user that had text searchdictionaries or configurations used to fail with:ERROR: unexpected classid 3600orERROR: unexpected classid 3602Fix by adding cases for those object types in a switch in pg_shdepend.c.Both REASSIGN OWNED and text search objects go back all the way to 8.1,so backpatch to all supported branches. In 9.3 the alter-owner code wasmade generic, so the required change in recent branches is prettysimple; however, for 9.2 and older ones we need some additionalreshuffling to enable specifying objects by OID rather than name.Text search templates and parsers are not owned objects, so there's nochange required for them.Per bug #9749 reported by Michal Novotný
1 parentc9e1ad7 commit6bdf4b9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎src/backend/catalog/pg_shdepend.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@
4040
#include"catalog/pg_proc.h"
4141
#include"catalog/pg_shdepend.h"
4242
#include"catalog/pg_tablespace.h"
43+
#include"catalog/pg_ts_config.h"
44+
#include"catalog/pg_ts_dict.h"
4345
#include"catalog/pg_type.h"
4446
#include"commands/alter.h"
4547
#include"commands/dbcommands.h"
@@ -1394,6 +1396,8 @@ shdepReassignOwned(List *roleids, Oid newrole)
13941396
caseExtensionRelationId:
13951397
caseTableSpaceRelationId:
13961398
caseDatabaseRelationId:
1399+
caseTSConfigRelationId:
1400+
caseTSDictionaryRelationId:
13971401
{
13981402
OidclassId=sdepForm->classid;
13991403
Relationcatalog;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp