From b6a1d25b0aa179c86e0607d4c0c3b647dc5bbb87 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Sun, 27 Jul 2003 04:53:12 +0000 Subject: Error message editing in utils/adt. Again thanks to Joe Conway for doing the bulk of the heavy lifting ... --- src/backend/utils/adt/sets.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src/backend/utils/adt/sets.c') diff --git a/src/backend/utils/adt/sets.c b/src/backend/utils/adt/sets.c index 6cb06735b15..a611f7271a8 100644 --- a/src/backend/utils/adt/sets.c +++ b/src/backend/utils/adt/sets.c @@ -10,7 +10,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.55 2002/12/13 19:45:56 tgl Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.56 2003/07/27 04:53:10 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -83,7 +83,7 @@ SetDefine(char *querystr, Oid elemType) ObjectIdGetDatum(setoid), 0, 0, 0); if (!HeapTupleIsValid(tup)) - elog(ERROR, "SetDefine: unable to define set %s", querystr); + elog(ERROR, "cache lookup failed for function %u", setoid); /* * We can tell whether the set was already defined by checking the @@ -201,7 +201,10 @@ seteval(PG_FUNCTION_ARGS) if (rsi && IsA(rsi, ReturnSetInfo)) rsi->isDone = isDone; else - elog(ERROR, "Set-valued function called in context that cannot accept a set"); + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("set-valued function called in context that " + "cannot accept a set"))); } PG_RETURN_DATUM(result); -- cgit v1.2.3