mirror of
https://github.com/postgres/postgres.git
synced 2025-11-12 05:01:15 +03:00
Change warnings for non-existing or pre-existing cursors to errors.
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/mmgr/portalmem.c,v 1.61 2003/08/04 02:40:08 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/utils/mmgr/portalmem.c,v 1.62 2003/08/24 21:02:43 petere Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -167,11 +167,11 @@ CreatePortal(const char *name, bool allowDup, bool dupSilent)
|
||||
if (!allowDup)
|
||||
ereport(ERROR,
|
||||
(errcode(ERRCODE_DUPLICATE_CURSOR),
|
||||
errmsg("portal \"%s\" already exists", name)));
|
||||
errmsg("cursor \"%s\" already exists", name)));
|
||||
if (!dupSilent)
|
||||
ereport(WARNING,
|
||||
(errcode(ERRCODE_DUPLICATE_CURSOR),
|
||||
errmsg("closing pre-existing portal \"%s\"",
|
||||
errmsg("closing existing cursor \"%s\"",
|
||||
name)));
|
||||
PortalDrop(portal, false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user