Cosmetic change in catalog/index.c - Mailing list pgsql-patches
From | Greg Sabino Mullane |
---|---|
Subject | Cosmetic change in catalog/index.c |
Date | |
Msg-id | 0845c4e450b46ea37530e68f04c7f58e@biglumber.com Whole thread Raw |
Responses |
Re: Cosmetic change in catalog/index.c
|
List | pgsql-patches |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 NotDashEscaped: You need GnuPG to verify this message Very minor cosmetic patch to catalog/index.c: I noticed when replying to bug #895 that the error message "relation already exists" is not capitilized as the rest are: ERROR: relation named "pk_exchange_batch_idx" already exists This patch fixes that and a few other places where the capitilization is needed. -- Greg Sabino Mullane greg@turnstep.com PGP Key: 0x14964AC8 200302131005 Index: index.c =================================================================== RCS file: /projects/cvsroot/pgsql-server/src/backend/catalog/index.c,v retrieving revision 1.208 diff -c -r1.208 index.c *** index.c 2002/12/15 16:17:38 1.208 --- index.c 2003/02/13 15:04:27 *************** *** 235,241 **** * here we are indexing on a normal attribute (1...n) */ if (atnum > natts) ! elog(ERROR, "cannot create index: column %d does not exist", atnum); from = heapTupDesc->attrs[AttrNumberGetAttrOffset(atnum)]; --- 235,241 ---- * here we are indexing on a normal attribute (1...n) */ if (atnum > natts) ! elog(ERROR, "Cannot create index: column %d does not exist", atnum); from = heapTupDesc->attrs[AttrNumberGetAttrOffset(atnum)]; *************** *** 540,546 **** */ if (indexInfo->ii_NumIndexAttrs < 1 || indexInfo->ii_NumKeyAttrs < 1) ! elog(ERROR, "must index at least one column"); if (!allow_system_table_mods && IsSystemRelation(heapRelation) && --- 540,546 ---- */ if (indexInfo->ii_NumIndexAttrs < 1 || indexInfo->ii_NumKeyAttrs < 1) ! elog(ERROR, "Must index at least one column"); if (!allow_system_table_mods && IsSystemRelation(heapRelation) && *************** *** 558,564 **** elog(ERROR, "Shared indexes cannot be created after initdb"); if (get_relname_relid(indexRelationName, namespaceId)) ! elog(ERROR, "relation named \"%s\" already exists", indexRelationName); /* --- 558,564 ---- elog(ERROR, "Shared indexes cannot be created after initdb"); if (get_relname_relid(indexRelationName, namespaceId)) ! elog(ERROR, "Relation named \"%s\" already exists", indexRelationName); /* *************** *** 671,677 **** constraintType = CONSTRAINT_UNIQUE; else { ! elog(ERROR, "index_create: constraint must be PRIMARY or UNIQUE"); constraintType = 0; /* keep compiler quiet */ } --- 671,677 ---- constraintType = CONSTRAINT_UNIQUE; else { ! elog(ERROR, "Index_create: constraint must be PRIMARY or UNIQUE"); constraintType = 0; /* keep compiler quiet */ } *************** *** 1036,1042 **** if (heaprel->rd_rel->relkind != RELKIND_RELATION && heaprel->rd_rel->relkind != RELKIND_TOASTVALUE) ! elog(ERROR, "relation %s isn't an indexable relation", RelationGetRelationName(heaprel)); /* If pg_class.relhasindex is set, indexes are active */ --- 1036,1042 ---- if (heaprel->rd_rel->relkind != RELKIND_RELATION && heaprel->rd_rel->relkind != RELKIND_TOASTVALUE) ! elog(ERROR, "Relation %s isn't an indexable relation", RelationGetRelationName(heaprel)); /* If pg_class.relhasindex is set, indexes are active */ *************** *** 1796,1808 **** if (iRel->rd_rel->relisshared) { if (!IsIgnoringSystemIndexes()) ! elog(ERROR, "the target relation %u is shared", indexId); inplace = true; } if (iRel->rd_isnailed) { if (!IsIgnoringSystemIndexes()) ! elog(ERROR, "the target relation %u is nailed", indexId); inplace = true; } --- 1796,1808 ---- if (iRel->rd_rel->relisshared) { if (!IsIgnoringSystemIndexes()) ! elog(ERROR, "The target relation %u is shared", indexId); inplace = true; } if (iRel->rd_isnailed) { if (!IsIgnoringSystemIndexes()) ! elog(ERROR, "The target relation %u is nailed", indexId); inplace = true; } *************** *** 1919,1925 **** deactivate_needed = true; } else ! elog(ERROR, "the target relation %u is shared", relid); } old = SetReindexProcessing(true); --- 1919,1925 ---- deactivate_needed = true; } else ! elog(ERROR, "The target relation %u is shared", relid); } old = SetReindexProcessing(true); -----BEGIN PGP SIGNATURE----- Comment: http://www.turnstep.com/pgp.html iD8DBQE+S7SDvJuQZxSWSsgRAmZFAKDcJbSmMbfWXMmekB/xopQ9Qtj8mACg19FB +hZkHs8APOZsWA5geYlTDD8= =ZIrU -----END PGP SIGNATURE-----
pgsql-patches by date: