Re: getting postgres to emulate mysql/sqlserver bit datatype

From: "Anton Melser" <melser(dot)anton(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Shane Ambler" <pgsql(at)007marketing(dot)com>, "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: getting postgres to emulate mysql/sqlserver bit datatype
Date: 2007-02-13 21:45:23
Message-ID: 92d3a4950702131345p18bfcc33qbf0578238f793916@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 13/02/07, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> "Anton Melser" <melser(dot)anton(at)gmail(dot)com> writes:
> > ERROR: operator is not unique: boolean = integer
>
> > I get this whether castcontext is 'a' or 'i'.
>
> If you make both cast directions the same priority then the system has
> no basis for choosing bool = bool over int = int or vice versa. Try
> making one direction 'i' and the other not. I'm not sure which one
> ought to be 'i', really --- it depends a lot on the details of the
> queries you are trying to make work.

That did the trick. Both seem to work, so for me that's great. Thanks
heaps. I may end up trying to get them to change it from 1 and 0 to
'1' and '0', as sql server accepts it, and if sql server accepts it, I
would be surprised if mysql doesn't...
Thanks again,
Anton

In response to

Browse pgsql-general by date

  From Date Subject
Next Message vanessa 2007-02-13 21:56:15 converting a specified year and week into a date
Previous Message Paul Lambert 2007-02-13 21:42:24 Re: PGSQL 8.2.3 Installation problem