diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2007-10-29 21:31:28 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2007-10-29 21:31:28 +0000 |
| commit | 2aae35d049274b6364aa01add629c33a1e2e6089 (patch) | |
| tree | 5de315330bd9a39931704d4f67d26d803411eb64 /src/backend/utils/sort | |
| parent | b17b7fae8c1418f924915348afaa2250d1360bc4 (diff) | |
| download | postgresql-2aae35d049274b6364aa01add629c33a1e2e6089.tar.gz | |
Mention the index name in 'could not create unique index' errors,
per suggestion from Rene Gollent.
Diffstat (limited to 'src/backend/utils/sort')
| -rw-r--r-- | src/backend/utils/sort/tuplesort.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/backend/utils/sort/tuplesort.c b/src/backend/utils/sort/tuplesort.c index 815dd2158d..0c63d1e142 100644 --- a/src/backend/utils/sort/tuplesort.c +++ b/src/backend/utils/sort/tuplesort.c @@ -91,7 +91,7 @@ * Portions Copyright (c) 1994, Regents of the University of California * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/utils/sort/tuplesort.c,v 1.78 2007/09/01 18:47:39 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/utils/sort/tuplesort.c,v 1.79 2007/10/29 21:31:28 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -2720,7 +2720,8 @@ comparetup_index(const SortTuple *a, const SortTuple *b, Tuplesortstate *state) if (state->enforceUnique && !equal_hasnull && tuple1 != tuple2) ereport(ERROR, (errcode(ERRCODE_UNIQUE_VIOLATION), - errmsg("could not create unique index"), + errmsg("could not create unique index \"%s\"", + RelationGetRelationName(state->indexRel)), errdetail("Table contains duplicated values."))); /* |
