From: | Dave Page <dpage(at)vale-housing(dot)co(dot)uk> |
---|---|
To: | Ludek Finstrle <luf(at)pzkagis(dot)cz>, Thomas Chabaud <tc(at)geosys(dot)com> |
Cc: | <pgsql-odbc(at)postgresql(dot)org> |
Subject: | Re: Annoying problem with UseDeclareFetch |
Date: | 2005-12-01 20:47:20 |
Message-ID: | BFB511D8.6C37%dpage@vale-housing.co.uk |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-odbc |
On 1/12/05 8:09 pm, "Ludek Finstrle" <luf(at)pzkagis(dot)cz> wrote:
>> I'm using VB 6.0 with postgreSQL v8.0 and ODBC Driver v8.1.1.
>> I have set the driver's option UseDeclareFetch to true in order to avoid
>> recordset paging problem, but with this option enabled, rs.RecordCount
>> is always equal to -1.
>
> Yes. It do it this way.
>
>> Is it normal ?
>
> It made older versions too becouse driver (with UseDeclareFetch turned
> on) change SELECT .. to DECLARE CURSOR FOR SELECT ...
> This SQL command return ok (no recordcount). Then is called fetch
> which get max "cache size" (in Data Source options) rows and
> backend return fetched count.
> It's need whole rewrite of psqlodbc to solve this problem.
Rewriting psqlODBC won't help. When you use declare/fetch the driver simply
doesn't know how many rows there are until it's fetched them all, nor does
it have any way of getting that info.
Regards, Dave
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Jireš | 2005-12-02 01:27:34 | SQLColAttributes and SQL_DESC_NULLABLE |
Previous Message | Ludek Finstrle | 2005-12-01 20:21:05 | Some changes |