Re: psqlODBC text length with no records

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Barry Bell <Barry(dot)Bell(at)hartehanks(dot)com>, Hiroshi Saito <hiroshi(at)winpg(dot)jp>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Hiroshi Inoue <inoue(at)tpf(dot)co(dot)jp>
Cc: Heikki Linnakangas <hlinnakangas(at)vmware(dot)com>, Anna Gershnik <agershnik(at)tableausoftware(dot)com>, "pgsql-odbc(at)postgresql(dot)org" <pgsql-odbc(at)postgresql(dot)org>
Subject: Re: psqlODBC text length with no records
Date: 2014-05-14 16:09:32
Message-ID: 5373953C.5060403@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

On 05/14/2014 09:03 AM, Barry Bell wrote:
> It has to be the Driver/Postgres because VFP does not determin the datatype
> (The driver does).

That does not preclude the possibility that it changes a data type to
meet its view of the world given that data type handling varies greatly
from on data system to another.

>
> With the B0=254(Max Varchar) in the connection string of the ODBC driver is suppose convert
> The "text" in postgres to varchar is the length is less then 254.
> The issue here is the length is 0 or null, this setting is ignored and returns "text".
>
> Can you provider anymore information on driver setting B0 (Max Varchar)

From here:

http://psqlodbc.projects.pgfoundry.org/docs/config.html

Max Varchar The maximum precision of the Varchar and BPChar(char[x])
types. The default is 254 which actually means 255 because of the null
terminator. Note, if you set this value higher than 254, Access will not
let you index on varchar columns!

From here:

Varchar can be used the same way Character can: you can index on it
(the index keys are padded with spaces to the length of the field,
because index keys must be a fixed length), it accepts null values, and
Varchar fields have a limit of 254 characters in a table or cursor.

If it where me I would set B0 = 253 to see what happens.

>
>
> Barry Bell

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Browse pgsql-odbc by date

  From Date Subject
Next Message Adrian Klaver 2014-05-14 16:18:33 Re: psqlODBC text length with no records
Previous Message Barry Bell 2014-05-14 16:08:49 Re: psqlODBC text length with no records