|
21 | 21 | *
|
22 | 22 | *
|
23 | 23 | * IDENTIFICATION
|
24 |
| - * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.86 1998/09/23 04:22:14 momjian Exp $ |
| 24 | + * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.87 1998/10/01 01:49:12 tgl Exp $ |
25 | 25 | *
|
26 | 26 | * Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
|
27 | 27 | *
|
@@ -2678,6 +2678,11 @@ dumpIndices(FILE *fout, IndInfo *indinfo, int numIndices,
|
2678 | 2678 |
|
2679 | 2679 | if (!tablename|| (!strcmp(indinfo[i].indrelname,tablename)))
|
2680 | 2680 | {
|
| 2681 | +/* We make the index belong to the owner of its table, |
| 2682 | + * which is not necessarily right but should answer 99% of the |
| 2683 | + * time. Would have to add owner name to IndInfo to do it right. |
| 2684 | + */ |
| 2685 | +becomeUser(fout,tblinfo[tableInd].usename); |
2681 | 2686 |
|
2682 | 2687 | strcpy(id1,fmtId(indinfo[i].indexrelname));
|
2683 | 2688 | strcpy(id2,fmtId(indinfo[i].indrelname));
|
|