Re: [GENERAL] convert integer to bool implicitly

2005-12-18 Thread Sim Zacks
I got it working. This has been bothering me for a long time, but now that it was listed as an official bug in my system, I had to deal with it. I'll post the solution under a new post, because I think this will help a lot of people. Sim Zacks wrote: I know I can do it explicitly, I need to

Re: [GENERAL] convert integer to bool implicitly

2005-12-18 Thread Sim Zacks
I know I can do it explicitly, I need to do it implicitly. I am having a problem with a Microsoft Access front-end , that uses -1 as true and 0 as false. I have everything worked around all the places where I could find it by using a cbool(), but this doesn't work with filters, which probably ca

Re: [GENERAL] convert integer to bool implicitly

2005-12-18 Thread Andreas Kretschmer
Sim Zacks <[EMAIL PROTECTED]> schrieb: > How easy would it be to write a small type extension to have integer > automatically convert to bool? > For example, I want an implicit conversion that 0 is false and everything > else is true. test=# \d foo; Table "public.foo" Column | Type |

[GENERAL] convert integer to bool implicitly

2005-12-18 Thread Sim Zacks
How easy would it be to write a small type extension to have integer automatically convert to bool? For example, I want an implicit conversion that 0 is false and everything else is true. Is this C programming or can you do it with a local procedural language? Thanks Sim -