Skip site navigation (1) Skip section navigation (2)

cursor control

From: Johann Zuschlag <zuschlag2(at)online(dot)de>
To: dpage(at)vale-housing(dot)co(dot)uk
Cc: pgsql-odbc(at)postgresql(dot)org
Subject: cursor control
Date: 2005-10-07 14:52:43
Message-ID: 43468BBB.3000402@online.de (view raw or flat)
Thread:
Lists: pgsql-odbc
Hi Dave,

I don't understand the following in qresult.c:

503:        /* Speed up access */
504:        int                     fetch_count = self->fetch_count;

And then:

515:        if (fetch_count < fetch_count)
516:        {
517:                /* return a row from cache */
518:                mylog("next_tuple: fetch_count < fcount:
          returning tuple %d, fcount = %d\n", fetch_count, num_backend_rows);
519:                self->tupleField = the_tuples + (fetch_count * self->num_fields);               /* next row */
520:                self->fetch_count++;
521:                return TRUE;
522:        }
523:        else if (self->num_backend_rows < self->cache_size)

Maybe I'm misled. But  I assume (fetch_count < fetch_count) will never 
become true.

Regards
Johann


In response to

pgsql-odbc by date

Next:From: Dave PageDate: 2005-10-07 15:06:35
Subject: Re: cursor control
Previous:From: Dave PageDate: 2005-10-07 14:34:48
Subject: Re: CVS Moved

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group