Text field truncated using ADO/ODBC
am 22.08.2008 18:16:13 von billI am new to PostgreSQL and running 8.3 on Windows. I am connecting
using ADO and the ODBC driver. I have a table the contains a Varchar(80)
column and a Text column as well as a couple of integer and datetime
columns. My connection string contains TextAsLongVarchar=1 and
MaxLongVarcharSize=65536, however, my Text column is being truncated at
254 bytes (the value of MaxVarcharSize).
Adding UnknownAsLongVarchar=1 to the connection string causes ADO to see
Text column as LongVarchar and return its complete value but it also
causes the Varchar column to be seen as LongVarChar. This suggests that
the driver sees both Text and Varchar as unknown types.
What must I do to get the ODBC driver to see the Text column as
LongVarchar and the Varchar column as Varchar? The complete connection
string follows by signature.
Thanks.
Bill
Provider=MSDASQL.1;Extended Properties="DRIVER={PostgreSQL
ANSI};DATABASE=app;SERVER=localhost;PORT=5432;UID=postgres;P WD=*;SSLmode=disable;ReadOnly=0;Protocol=7.4-1;FakeOidIndex= 0;ShowOidColumn=0;RowVersioning=0;ShowSystemTables=0;ConnSet tings=;Fetch=100;Socket=4096;UnknownSizes=0;MaxVarcharSize=2 048;MaxLongVarcharSize=65536;Debug=0;CommLog=0;Optimizer=1;K sqo=1;UseDeclareFetch=0;TextAsLongVarchar=1;UnknownsAsLongVa rchar=0;BoolsAsChar=1;Parse=0;CancelAsFreeStmt=0;ExtraSysTab lePrefixes=dd_;;LFConversion=1;UpdatableCursors=1;DisallowPr emature=0;TrueIsMinus1=0;BI=0;ByteaAsLongVarBinary=0;UseServ erSidePrepare=0;LowerCaseIdentifier=0;XaOpt=1"
--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc