pg.ddx.io pgsql-odbc@postgresql.org mailing list archivehelp / color / mirror / Atom feed
Text as long varchar? 3+ messages / 2 participants [nested] [flat]
* Text as long varchar? @ 2002-08-19 08:51 Stelios Sfakianakis <ssfak@ics.forth.gr> 0 siblings, 0 replies; 3+ messages in thread From: Stelios Sfakianakis @ 2002-08-19 08:51 UTC (permalink / raw) To: pgsql-odbc Hi, I have the following configuration: - PostgreSQL 7.2.1 - PostgreSQL odbc driver 7.2.1 - Driver Manager: iodbc 3.0.5 - OTL <http://members.fortunecity.com/skuchin/home.htm; - FreeBSD 4.6 I try to read a TEXT column though the OTL's otl_long_string and I get an error because the type of column as returned by the odbc driver seems to be VARCHAR instead of VARCHAR_LONG. Perusing the odbc.postgresql.org site I found in the advanced options section something relative: "Text as LongVarChar: Postgres TEXT type is mapped to SQLLongVarchar, otherwise SQLVarchar" So although that this refers to the Win version of the odbc driver I put "TextAsLongVarchar = Yes" in both odbc.ini and odbcinst.ini but without success. The contents of these two files are: //odbcinst.ini: [ODBC Drivers] PostgreSQL = Installed [PostgreSQL] Description = PostgreSQL driver for Linux & Win32 Driver = /usr/local/lib/libpsqlodbc.so Setup = /usr/local/lib/libpsqlodbc.so FileUsage = 0 TextAsLongVarchar = Yes //odbc.ini: [TEST] Description = Test Database Driver = /usr/local/lib/libpsqlodbc.so Trace = Yes TraceFile = sql.log Database = test Servername = localhost UserName = Password = Port = 5432 Protocol = 6.4 ReadOnly = No RowVersioning = No ShowSystemTables = No ShowOidColumn = No FakeOidIndex = No TextAsLongVarchar = Yes ConnSettings = Any suggestions? Thanks for your time Stelios -- Thus spake the master programmer: ``After three days without programming, life becomes meaningless.'' --- The Tao of Programming ^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Text as long varchar? @ 2002-08-19 16:46 Janet Borschowa <borschow@roguewave.com> 0 siblings, 1 reply; 3+ messages in thread From: Janet Borschowa @ 2002-08-19 16:46 UTC (permalink / raw) To: pgsql-odbc; +Cc: Stelios Sfakianakis <ssfak@ics.forth.gr> Hi, Try using: TextAsLongVarchar=1 Note that there are no spaces around "=". ======================== Janet Borschowa Software Engineer, Database Products Rogue Wave Software (541) 753-1931 FAX: (541) 757-4630 borschow@roguewave.com http://www.roguewave.com -----Original Message----- From: Stelios Sfakianakis [mailto:ssfak@ics.forth.gr] Sent: Monday, August 19, 2002 1:52 AM To: pgsql-odbc@postgresql.org Subject: [ODBC] Text as long varchar? Hi, I have the following configuration: - PostgreSQL 7.2.1 - PostgreSQL odbc driver 7.2.1 - Driver Manager: iodbc 3.0.5 - OTL <http://members.fortunecity.com/skuchin/home.htm; - FreeBSD 4.6 I try to read a TEXT column though the OTL's otl_long_string and I get an error because the type of column as returned by the odbc driver seems to be VARCHAR instead of VARCHAR_LONG. Perusing the odbc.postgresql.org site I found in the advanced options section something relative: "Text as LongVarChar: Postgres TEXT type is mapped to SQLLongVarchar, otherwise SQLVarchar" So although that this refers to the Win version of the odbc driver I put "TextAsLongVarchar = Yes" in both odbc.ini and odbcinst.ini but without success. The contents of these two files are: //odbcinst.ini: [ODBC Drivers] PostgreSQL = Installed [PostgreSQL] Description = PostgreSQL driver for Linux & Win32 Driver = /usr/local/lib/libpsqlodbc.so Setup = /usr/local/lib/libpsqlodbc.so FileUsage = 0 TextAsLongVarchar = Yes //odbc.ini: [TEST] Description = Test Database Driver = /usr/local/lib/libpsqlodbc.so Trace = Yes TraceFile = sql.log Database = test Servername = localhost UserName = Password = Port = 5432 Protocol = 6.4 ReadOnly = No RowVersioning = No ShowSystemTables = No ShowOidColumn = No FakeOidIndex = No TextAsLongVarchar = Yes ConnSettings = Any suggestions? Thanks for your time Stelios -- Thus spake the master programmer: ``After three days without programming, life becomes meaningless.'' --- The Tao of Programming ---------------------------(end of broadcast)--------------------------- TIP 6: Have you searched our list archives? http://archives.postgresql.org ^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Text as long varchar? @ 2002-08-20 13:07 Stelios Sfakianakis <ssfak@ics.forth.gr> parent: Janet Borschowa <borschow@roguewave.com> 0 siblings, 0 replies; 3+ messages in thread From: Stelios Sfakianakis @ 2002-08-20 13:07 UTC (permalink / raw) To: pgsql-odbc Janet Borschowa wrote: > Hi, > Try using: > TextAsLongVarchar=1 > Note that there are no spaces around "=". > Yes it works! Thank you very much! Stelios > ======================== > Janet Borschowa > Software Engineer, Database Products > Rogue Wave Software > (541) 753-1931 FAX: (541) 757-4630 > borschow@roguewave.com http://www.roguewave.com > > > -----Original Message----- > From: Stelios Sfakianakis [mailto:ssfak@ics.forth.gr] > Sent: Monday, August 19, 2002 1:52 AM > To: pgsql-odbc@postgresql.org > Subject: [ODBC] Text as long varchar? > > > Hi, > I have the following configuration: > - PostgreSQL 7.2.1 > - PostgreSQL odbc driver 7.2.1 > - Driver Manager: iodbc 3.0.5 > - OTL <http://members.fortunecity.com/skuchin/home.htm; > - FreeBSD 4.6 > I try to read a TEXT column though the OTL's otl_long_string and I get > an error because the type of column as returned by the odbc driver seems > to be VARCHAR instead of VARCHAR_LONG. Perusing the odbc.postgresql.org > site I found in the advanced options section something relative: "Text > as LongVarChar: Postgres TEXT type is mapped to SQLLongVarchar, > otherwise SQLVarchar" > So although that this refers to the Win version of the odbc driver I put > "TextAsLongVarchar = Yes" in both odbc.ini and odbcinst.ini but without > success. The contents of these two files are: > > //odbcinst.ini: > [ODBC Drivers] > PostgreSQL = Installed > > [PostgreSQL] > Description = PostgreSQL driver for Linux & Win32 > Driver = /usr/local/lib/libpsqlodbc.so > Setup = /usr/local/lib/libpsqlodbc.so > FileUsage = 0 > TextAsLongVarchar = Yes > > //odbc.ini: > [TEST] > Description = Test Database > Driver = /usr/local/lib/libpsqlodbc.so > Trace = Yes > TraceFile = sql.log > Database = test > Servername = localhost > UserName = > Password = > Port = 5432 > Protocol = 6.4 > ReadOnly = No > RowVersioning = No > ShowSystemTables = No > ShowOidColumn = No > FakeOidIndex = No > TextAsLongVarchar = Yes > ConnSettings = > > Any suggestions? > > Thanks for your time > Stelios > -- Thus spake the master programmer: ``After three days without programming, life becomes meaningless.'' --- The Tao of Programming ^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2002-08-20 13:07 UTC | newest] Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2002-08-19 08:51 Text as long varchar? Stelios Sfakianakis <ssfak@ics.forth.gr> 2002-08-19 16:46 Re: Text as long varchar? Janet Borschowa <borschow@roguewave.com> 2002-08-20 13:07 ` Stelios Sfakianakis <ssfak@ics.forth.gr>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox