select from a table having more than 32 fields: Quick Workaround

From: "Matteo Cavalleri" <theos(at)bp(dot)lnf(dot)it>
To: pgsql-odbc(at)postgresql(dot)org
Subject: select from a table having more than 32 fields: Quick Workaround
Date: 2001-02-21 15:49:48
Message-ID: 3A93F1AC.22574.8EB290@localhost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

Description:
A select from a table having more than 32 fields fails during
SQLDescribeCol on field # 33.

Test:
create a 52 fields table. Insert 1 record. select * from table name.
The error comes out.
I get the error on a table with 52 field using psqlodbc version
6.50.000, Borland C++Builder or Centura.

What's going on?
In my opinion the driver try to allocate space for fields in blocks of
32 items as defined in FLD_INCR (parse.c) . The realloc() works
well but for some reasons the fi pointer seems to get lost during
SQLDescribeCol on column 1.

Quick workaround:
increase FLD_INCR, from 32 to how you need.
Byron will help better....

Responses

Browse pgsql-odbc by date

  From Date Subject
Next Message Tom Lane 2001-02-21 23:56:07 Re: select from a table having more than 32 fields: Quick Workaround
Previous Message Cedar Cox 2001-02-21 15:25:55 Re: ODBC Driver regedit file.