X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 685A6D1D32C for ; Tue, 20 Jan 2004 14:58:06 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 38864-07 for ; Tue, 20 Jan 2004 10:57:39 -0400 (AST) Received: from rwcrmhc12.comcast.net (rwcrmhc12.comcast.net [216.148.227.85]) by svr1.postgresql.org (Postfix) with ESMTP id 20026D1D179 for ; Tue, 20 Jan 2004 10:57:35 -0400 (AST) Received: from ranger (c-24-17-160-6.client.comcast.net[24.17.160.6]) by comcast.net (rwcrmhc12) with SMTP id <20040120145738014004o6jae>; Tue, 20 Jan 2004 14:57:38 +0000 Content-Type: text/plain; charset="iso-8859-1" From: Adrian Klaver Reply-To: aklaver@attbi.com To: pgsql-odbc@postgresql.org Subject: Re: ms-access and booleans ? Date: Tue, 20 Jan 2004 07:07:21 -0800 User-Agent: KMail/1.4.3 References: <20040119153613.31921.qmail@web20813.mail.yahoo.com> In-Reply-To: <20040119153613.31921.qmail@web20813.mail.yahoo.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200401200707.21552.aklaver@comcast.net> X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200401/58 X-Sequence-Number: 3687 On Monday 19 January 2004 07:36 am, Jeff Eckermann wrote: > --- Andreas wrote: > > Hi, > > > > I transferred a couple of tables from an Access MDB > > to Postgres. > > Among the involved column-types are booleans. > > > > I could dump the contend of the Access table to PG > > via an odbc linked table. > > > > In psql I can run : > > SELECT count(*) FROM my_table WHERE > > some_boolean; > > It shows some number as expected. > > > > I Access I get an Error: > > ODBC-Call failed. > > Error: Operator doesn't exist: boolean =3D integer > > (#7) > > > > In the System-DSN I have > > Bool as Char : NO > > True is -1 : YES > > You should have success by playing with these > settings. I use different settings, but that is a > historical matter. I believe that the ODBC driver > handling of booleans for MS Access has been optimized > somewhat in recent releases. Probably just setting > "bool as char" to true will do it. But I admit that I > haven't played with these lately, not wanting to mess > up a working setup. > > > How can have booleans that don't break my Access > > front-end ? > > > > > > cu > > Andreas > > > > > > ---------------------------(end of > > broadcast)--------------------------- > > TIP 2: you can get off all lists at once with the > > unregister command > > (send "unregister YourEmailAddressHere" to > > majordomo@postgresql.org) > > > __________________________________ > Do you Yahoo!? > Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes > http://hotjobs.sweepstakes.yahoo.com/signingbonus > > ---------------------------(end of broadcast)--------------------------- > TIP 3: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly =20 The way I have handled this is to avoid check boxes and use a combo box=20 instead. I supply the values as True;1 ,False;0 and bind the field to the= =20 second value of each pair. To make things easier for data entry I hide the= =20 second column by giving it a width of 0". In my DSN settings I check bool = as=20 char and uncheck true as -1.=20 --=20 Adrian Klaver=09 aklaver@comcast.net