Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id 28D39F765A for ; Wed, 11 Apr 2012 16:21:46 -0300 (ADT) Received: from 200-170-190-097.xf-static.ctbcnetsuper.com.br ([200.170.190.97] helo=host1.ad2.com.br) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SI36s-0005ed-U7 for pgsql-odbc@postgresql.org; Wed, 11 Apr 2012 19:21:46 +0000 Received: by host1.ad2.com.br (Postfix, from userid 1002) id C877B565049; Wed, 11 Apr 2012 16:20:53 -0300 (BRT) Received: from spamhunter.AD2 (unknown [192.168.1.223]) by host1.ad2.com.br (Postfix) with ESMTPA id 90E63565020 for ; Wed, 11 Apr 2012 16:20:53 -0300 (BRT) Received: from [192.168.1.50] ([192.168.1.50] helo=[192.168.1.50]) by spamhunter.AD2 with ESMTP (ASSP 1.9); 11 Apr 2012 16:20:53 -0300 Message-ID: <4F85D9B8.10804@aldeiadigital.com.br> Date: Wed, 11 Apr 2012 16:21:28 -0300 From: Alexandre - Aldeia Digital User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120410 Thunderbird/11.0.1 MIME-Version: 1.0 CC: pgsql-odbc@postgresql.org Subject: Re: Problem with Use Declare/Fetch References: <4F624C5D.1010809@aldeiadigital.com.br> <4F627C3D.8070302@tpf.co.jp> <4F837001.9000207@aldeiadigital.com.br> <4F85896C.2050402@tpf.co.jp> In-Reply-To: <4F85896C.2050402@tpf.co.jp> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -0.9 (/) X-Archive-Number: 201204/8 X-Sequence-Number: 10822 Hi Hiroshi, Em 11-04-2012 10:38, Hiroshi Inoue escreveu: > Hi Alexandre, > > (2012/04/10 8:25), Alexandre - Aldeia Digital wrote: >> Hi Hiroshi, >> >> Sorry for delay! >> >> I sent the links to download the logs directly in your e-mail. >> I analyzed the logs and I believe that the error was in this cursor: >> >> [1168-47.972] stmt_with_params = 'declare "P00954" cursor for SELECT >> T1.Fn04CodEmp(...) >> >> This query must return about 14k rows. But with use/declare fectch (in >> this case, cache size = 10), returns only 10 rows. > > It seems OK to me. Psqlodbc driver fetches tuples using extended query > other than the 1st fetch. You can see the following lines in many > places > > SendExecuteRequest: plan_name=P00954 count=10 > > and the query returns 14725 tuples as a result. > > [1168-332.835]end of tuple list -- setting inUse to false: this = > 083A0810 SELECT 5 > ELECT 5 > [1168-332.835]_QR_next_tuple: 'C' fetch_total = 14725 & this_fetch = 5 > Very strange. I will try again and send you the results. >> I don't search in other areas, but if you need I can do this. >> >> Another doubt: My Rollback on erros is set to Transaction. But I can see >> some SAVEPOINT/RELEASE statements. It's normal ? > > Yes the driver uses savepoint/rollback in some internal queries. Ok. > regards, > Hiroshi Inoue Best regards, Alexandre