|
8 | 8 | *
|
9 | 9 | *
|
10 | 10 | * IDENTIFICATION
|
11 |
| - * $PostgreSQL: pgsql/src/backend/catalog/heap.c,v 1.289 2005/08/12 01:35:56 tgl Exp $ |
| 11 | + * $PostgreSQL: pgsql/src/backend/catalog/heap.c,v 1.290 2005/08/26 03:07:12 tgl Exp $ |
12 | 12 | *
|
13 | 13 | *
|
14 | 14 | * INTERFACE ROUTINES
|
|
65 | 65 | staticvoidAddNewRelationTuple(Relationpg_class_desc,
|
66 | 66 | Relationnew_rel_desc,
|
67 | 67 | Oidnew_rel_oid,Oidnew_type_oid,
|
| 68 | +Oidrelowner, |
68 | 69 | charrelkind);
|
69 | 70 | staticOidAddNewRelationType(constchar*typeName,
|
70 | 71 | OidtypeNamespace,
|
@@ -555,6 +556,7 @@ AddNewRelationTuple(Relation pg_class_desc,
|
555 | 556 | Relationnew_rel_desc,
|
556 | 557 | Oidnew_rel_oid,
|
557 | 558 | Oidnew_type_oid,
|
| 559 | +Oidrelowner, |
558 | 560 | charrelkind)
|
559 | 561 | {
|
560 | 562 | Form_pg_classnew_rel_reltup;
|
@@ -587,7 +589,7 @@ AddNewRelationTuple(Relation pg_class_desc,
|
587 | 589 | break;
|
588 | 590 | }
|
589 | 591 |
|
590 |
| -new_rel_reltup->relowner=GetUserId(); |
| 592 | +new_rel_reltup->relowner=relowner; |
591 | 593 | new_rel_reltup->reltype=new_type_oid;
|
592 | 594 | new_rel_reltup->relkind=relkind;
|
593 | 595 |
|
@@ -665,6 +667,7 @@ heap_create_with_catalog(const char *relname,
|
665 | 667 | Oidrelnamespace,
|
666 | 668 | Oidreltablespace,
|
667 | 669 | Oidrelid,
|
| 670 | +Oidownerid, |
668 | 671 | TupleDesctupdesc,
|
669 | 672 | charrelkind,
|
670 | 673 | boolshared_relation,
|
@@ -740,6 +743,7 @@ heap_create_with_catalog(const char *relname,
|
740 | 743 | new_rel_desc,
|
741 | 744 | relid,
|
742 | 745 | new_type_oid,
|
| 746 | +ownerid, |
743 | 747 | relkind);
|
744 | 748 |
|
745 | 749 | /*
|
@@ -769,7 +773,7 @@ heap_create_with_catalog(const char *relname,
|
769 | 773 | referenced.objectSubId=0;
|
770 | 774 | recordDependencyOn(&myself,&referenced,DEPENDENCY_NORMAL);
|
771 | 775 |
|
772 |
| -recordDependencyOnOwner(RelationRelationId,relid,GetUserId()); |
| 776 | +recordDependencyOnOwner(RelationRelationId,relid,ownerid); |
773 | 777 | }
|
774 | 778 |
|
775 | 779 | /*
|
|