X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 250D1D1C9C3 for ; Wed, 30 Jul 2003 08:57:36 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 43643-05 for ; Wed, 30 Jul 2003 05:56:36 -0300 (ADT) Received: from curie.credativ.org (credativ.com [217.160.209.18]) by svr1.postgresql.org (Postfix) with ESMTP id 5AB95D1C9C0 for ; Wed, 30 Jul 2003 05:57:34 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by curie.credativ.org (Postfix) with ESMTP id 6A25E55EFA for ; Wed, 30 Jul 2003 10:57:35 +0200 (CEST) Received: from [172.26.14.239] (p50925BC7.dip.t-dialin.net [80.146.91.199]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by curie.credativ.org (Postfix) with ESMTP id E579655EF6 for ; Wed, 30 Jul 2003 10:57:34 +0200 (CEST) Date: Wed, 30 Jul 2003 11:06:39 +0200 (CEST) From: Peter Eisentraut X-X-Sender: peter@krusty.credativ.de To: pgsql-sql@postgresql.org Subject: Which cursor-related warnings should be errors? Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by AMaViS X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200307/446 X-Sequence-Number: 14560 The developers are currently discussing changing several cursor-related warnings to hard errors. If PostgreSQL were to be designed from scratch, there would hardly be discussion about this, but now we are wondering whether any existing users would seriously be affected by this change. The cases under consideration are: Fetching from a non-existent cursor: peter=# FETCH ALL FROM non_existent; WARNING: portal "non_existent" does not exist FETCH 0 Closing a non-existent cursor: peter=# CLOSE non_existent; WARNING: portal "non_existent" does not exist CLOSE CURSOR Declaring a new cursor that uses a name already in use: peter=# BEGIN; BEGIN peter=# DECLARE foo CURSOR FOR SELECT 1; DECLARE CURSOR peter=# DECLARE foo CURSOR FOR SELECT 2; WARNING: Closing pre-existing portal "foo" DECLARE CURSOR So if anyone can come up with a reason that theses WARNING: messages should not be changed to errors, please speak up. -- Peter Eisentraut peter_e@gmx.net