Skip site navigation (1) Skip section navigation (2)

Re: Issue in Mapping varchar datatype of Postgre to Oracle

From: Joerg Hessdoerfer <Joerg(dot)Hessdoerfer(at)sea-gmbh(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Issue in Mapping varchar datatype of Postgre to Oracle
Date: 2006-03-29 08:04:39
Message-ID: 200603291004.40801.Joerg.Hessdoerfer@sea-gmbh.com (view raw or flat)
Thread:
Lists: pgsql-hackers
Hi,

On Wednesday 29 March 2006 07:32, vidisha(dot)shah(at)tcs(dot)com wrote:
> Hi
>
> We are trying to fetch records from Postgre Tables.
>
> We are successfully able to build connectivity. We are Using Postgre ODBC
> Driver (Unicode).
>
> But when I query the tables of Postgre it is unable to map the datatype
> varchar of source Table.
>
> We got following Reply from Oracle Support.
>
[...]
> .
> CAUSE DETERMINATION
> ====================
> VARCHAR datatype from PostgreSQL is translated by your ODBC driver in an
> unsupported datatype for HSODBC.
>
>
> CAUSE JUSTIFICATION
> ====================
> In the trace file, you get the datatype from postgreSQL
> ====>1043 VARCHAR(50)
>
> then you get the datatype that ODBC driver is mapping to get back to
> Oracle
> ====>[4464]describeCol: col 2 *pfSqlType = -9
>
> If you look at in the Note 252548.1,
> -9 is SQL_WVARCHAR
>
> and unfortunately this ODBC datatype is not supported by the Generic
> Connectivity agent (HSODBC).
>
[...]
>--------------------------------
>
> Can you please suggest why varchar datatype is not correctly identified
> and what is the path to get solution?
>
> Thanks & Regards
>
> Vidisha B Shah
>
[...]

Well, it ist certainly not 'not correctly identified'. The opposite is true. 
It is absolutely correctly identified. It's just that the vendor of 
HSODBC ;-) doesn't fully support all ODBC datatypes (especially Unicode wide 
character types). You could try to use SQL_ASCII, or another 8-Bit only 
codepage to get around this.

HTH,
	Jörg
-- 
Leiter Softwareentwicklung - S.E.A GmbH
Mail: joerg(dot)hessdoerfer(at)sea-gmbh(dot)com
WWW:  http://www.sea-gmbh.com

In response to

pgsql-hackers by date

Next:From: Simon RiggsDate: 2006-03-29 08:08:27
Subject: Re: Issue in Mapping varchar datatype of Postgre to
Previous:From: vidisha.shahDate: 2006-03-29 05:32:19
Subject: Issue in Mapping varchar datatype of Postgre to Oracle

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group