Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Postgresql, booleans and EOM
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Postgresql, booleans and EOM



Thanks Giorio. I modified my EOModel to the way you've described, but the accessor methods that EOMOdeler creates in my EO still have Number as the return value. Do I just leave those alone?

Thanks
MIke
On Aug 25, 2004, at 3:06 PM, Giorgio Valoti wrote:

On 25/ago/04, at 15:49, Michael Engelhart wrote:

Hi -

What are the Postgresql developers out there using for booleans in Postgresql so that it works in EOModeler? I've read a bunch of different posts in the archives but can't seem to conclude which works best for Postgres. I have tried both Integers and chars to store 0/1 or t/f in the database and have the cover method convert to a boolean but is there a better way?

This should work:

...
columnName = <YOUR_COLUMN_NAME>;
externalType = bool;
name = <yourAttrName>;
valueClassName = NSNumber;
valueType = c;
...

No need for cover methods, EOGenericRecord is just fine.

Hope this helps

--
Giorgio Valoti
--------------
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >Postgresql, booleans and EOM (From: Michael Engelhart <email@hidden>)
 >Re: Postgresql, booleans and EOM (From: Giorgio Valoti <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.