X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 43E4BD706A for ; Mon, 29 Aug 2005 17:52:08 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 94898-01 for ; Mon, 29 Aug 2005 20:52:04 +0000 (GMT) Received: from home.nohrsc.nws.gov (home.nohrsc.nws.gov [192.46.108.2]) by svr1.postgresql.org (Postfix) with ESMTP id 09B99D6E21 for ; Mon, 29 Aug 2005 17:52:02 -0300 (ADT) Received: from noaa.gov (opps-gw.nohrsc.nws.gov [192.46.108.142]) by home.nohrsc.nws.gov (Postfix) with ESMTP id 6AFCDA5D2; Mon, 29 Aug 2005 15:52:02 -0500 (CDT) Message-ID: <43137572.4090107@noaa.gov> Date: Mon, 29 Aug 2005 15:52:02 -0500 From: andy rost User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Michael Fuhr Cc: pgsql-sql@postgresql.org Subject: Re: sqlstate 02000 while declaring cursor/freeing prepared References: <431361D8.8050900@noaa.gov> <20050829200935.GA98664@winnie.fuhr.org> In-Reply-To: <20050829200935.GA98664@winnie.fuhr.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.05 required=5 tests=[FORGED_RCVD_HELO=0.05] X-Spam-Level: X-Archive-Number: 200508/272 X-Sequence-Number: 22500 Sure. I'm using ECPG (ecpg -t -r no_indicator -C INFORMIX) in a TRU64 operating system for PostgreSQL version 8.0.2. By occasionally, I mean that I don't observe this problems for each declare and free statement that I've encoded - only for a subset of those commands. But I do observe this problem consistently within that subset - the same command fails every time for a small number of declares and frees. Unfortunately, I do not have a case that can be easily reproduced. The commands that fail are part of a large system. It seems like an odd error for these kinds of commands. Thanks ... Andy Michael Fuhr wrote: > On Mon, Aug 29, 2005 at 02:28:24PM -0500, andy rost wrote: > >>I'm in the process of porting Informix ESQL to PostgreSQL. I >>occasionally get sqlcode = 100 and sqlstate = 02000 when declaring >>cursors or freeing prepared statements. Is this normal? For example: >> >> $declare loop1 cursor with hold for >> select distinct ( tabname ) >> from meta ; >> >>results in sqlca.sqlcode = 100 and sqlca.sqlstate = '02000' > > > Could you provide a little more context? Are you using ECPG? What > version of PostgreSQL are you using? When you say that you > "occasionally" see this behavior, do you mean that you see it > consistently with some commands and not with others, or do you mean > that the same command sometimes does it and sometimes not? > > Do you have a reproducible test case? That is, everything that > somebody could do to reproduce the behavior on their own system? > -- -------------------------------------------------------------------------------- Andrew Rost National Operational Hydrologic Remote Sensing Center (NOHRSC) National Weather Service, NOAA 1735 Lake Dr. West, Chanhassen, MN 55317-8582 Voice: (952)361-6610 x 234 Fax: (952)361-6634 arost@nohrsc.nws.gov http://www.nohrsc.nws.gov --------------------------------------------------------------------------------