*** pgsql/src/backend/commands/functioncmds.c 2008/07/18 03:32:52 1.98 --- pgsql/src/backend/commands/functioncmds.c 2008/10/21 10:38:51 1.99 *************** *** 10,16 **** * * * IDENTIFICATION ! * $PostgreSQL: pgsql/src/backend/commands/functioncmds.c,v 1.97 2008/07/16 16:55:23 tgl Exp $ * * DESCRIPTION * These routines take the parse tree and pick out the --- 10,16 ---- * * * IDENTIFICATION ! * $PostgreSQL: pgsql/src/backend/commands/functioncmds.c,v 1.98 2008/07/18 03:32:52 tgl Exp $ * * DESCRIPTION * These routines take the parse tree and pick out the *************** CreateCast(CreateCastStmt *stmt) *** 1412,1419 **** ereport(ERROR, (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE), errmsg("must be owner of type %s or type %s", ! TypeNameToString(stmt->sourcetype), ! TypeNameToString(stmt->targettype)))); if (stmt->func != NULL) { --- 1412,1419 ---- ereport(ERROR, (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE), errmsg("must be owner of type %s or type %s", ! format_type_be(sourcetypeid), ! format_type_be(targettypeid)))); if (stmt->func != NULL) { *************** CreateCast(CreateCastStmt *stmt) *** 1554,1561 **** ereport(ERROR, (errcode(ERRCODE_DUPLICATE_OBJECT), errmsg("cast from type %s to type %s already exists", ! TypeNameToString(stmt->sourcetype), ! TypeNameToString(stmt->targettype)))); /* ready to go */ values[Anum_pg_cast_castsource - 1] = ObjectIdGetDatum(sourcetypeid); --- 1554,1561 ---- ereport(ERROR, (errcode(ERRCODE_DUPLICATE_OBJECT), errmsg("cast from type %s to type %s already exists", ! format_type_be(sourcetypeid), ! format_type_be(targettypeid)))); /* ready to go */ values[Anum_pg_cast_castsource - 1] = ObjectIdGetDatum(sourcetypeid); *************** DropCast(DropCastStmt *stmt) *** 1629,1641 **** ereport(ERROR, (errcode(ERRCODE_UNDEFINED_OBJECT), errmsg("cast from type %s to type %s does not exist", ! TypeNameToString(stmt->sourcetype), ! TypeNameToString(stmt->targettype)))); else ereport(NOTICE, (errmsg("cast from type %s to type %s does not exist, skipping", ! TypeNameToString(stmt->sourcetype), ! TypeNameToString(stmt->targettype)))); return; } --- 1629,1641 ---- ereport(ERROR, (errcode(ERRCODE_UNDEFINED_OBJECT), errmsg("cast from type %s to type %s does not exist", ! format_type_be(sourcetypeid), ! format_type_be(targettypeid)))); else ereport(NOTICE, (errmsg("cast from type %s to type %s does not exist, skipping", ! format_type_be(sourcetypeid), ! format_type_be(targettypeid)))); return; } *************** DropCast(DropCastStmt *stmt) *** 1646,1653 **** ereport(ERROR, (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE), errmsg("must be owner of type %s or type %s", ! TypeNameToString(stmt->sourcetype), ! TypeNameToString(stmt->targettype)))); /* * Do the deletion --- 1646,1653 ---- ereport(ERROR, (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE), errmsg("must be owner of type %s or type %s", ! format_type_be(sourcetypeid), ! format_type_be(targettypeid)))); /* * Do the deletion