On Sun, 22 Jan 2006 15:46:11 -0500
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> "Jesper K. Pedersen" <jkp(at)solnet(dot)homeip(dot)net> writes:
> > I am have some difficulties converting the Microsoft field of type
> > YESNO (which is a simple boolean true/false) to something that is
> > compatible with PostgreSQL.
> Assume that we have no idea what that is ;-). What is the I/O format
> MSSQL uses for this datatype? Is YESNO actually the name of the type?
> If the problem is that Access is looking for that specific type name,
> you could probably fake it out by creating a domain:
> create domain yesno as boolean;
> create table foo (mycol yesno);
> This will only work if the I/O format is 't' and 'f', though.
> Otherwise you'll need to make the domain be over a type with
> suitable I/O format (perhaps integer or text will work).
Having checked the I/O format it seems that MS Access exports the
values of a YESNO field as 0 and 1
I have tried the workaround with creating a domain for various
datatypes but it wasnt passed through the odbc layer (have tried both
with Linux/PostgreSQL and native Microsoft PostgreSQL 8.1 server both
with the same result) :-\
Jesper K. Pedersen
In response to
pgsql-sql by date
|Next:||From: Achilleus Mantzios||Date: 2006-01-23 10:57:11|
|Subject: DBMirror.pl performance change|
|Previous:||From: Tom Lane||Date: 2006-01-22 20:46:11|
|Subject: Re: How to implement Microsoft Access boolean (YESNO) fieldtype in PostgreSQL ? |