• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [Wonder-disc] OpenBase / boolean / ERPrototypes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Wonder-disc] OpenBase / boolean / ERPrototypes


  • Subject: Re: [Wonder-disc] OpenBase / boolean / ERPrototypes
  • From: Mike Schrag <email@hidden>
  • Date: Sun, 8 Mar 2009 23:17:19 -0400

Not sure I understood what you mean by flag.  :-)
there is a prototype named "flag" that maps onto whatever your database considers a "bit" type -- if your database natively supports a boolean type, this is the one you would use, though there are good odds the definition is wrong for OB

Anyways, here's the boolean protototype from ERPrototypes as defined in EOJDBCOpenBasePrototypes.plist:
yes, this is the varchar(5) boolean type that turns into the strings "true" or "false" in the database.

and the intBoolean prototype is setup as follows:

        {
            adaptorValueConversionMethodName = toString;
            columnName = "";
            externalType = bool;
            factoryMethodArgumentType = EOFactoryMethodArgumentIsNSString;
            name = intBoolean;
            valueClassName = NSNumber;
            valueFactoryMethodName = valueOf;
            valueType = c;
        },
You're setting this up wrong .. you should look at the other databases versions of this in ERP ... you don't have/need a valueFactoryMethodName and a conversion method name for integer types .. it's much easier than that.

I've been trying all kinds of things to get these booleans to work...  And I just thought of one which might work.  I'll change the type in openbase for those columns back to integer type.  Then I'll use the intBoolean prototype from ERPrototypes.  I assume that's what the intBoolean prototype is for: to have a boolean in your EO stored as an integer in the database.  Right?
yes, though again, if you're using the "boolean" type, you're probably not going to want intBoolean (though it may work "by accident").

ms
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: [Wonder-disc] OpenBase / boolean / ERPrototypes
      • From: "Ricardo J. Parada" <email@hidden>
References: 
 >OpenBase / boolean / ERPrototypes (From: "Ricardo J. Parada" <email@hidden>)
 >Re: [Wonder-disc] OpenBase / boolean / ERPrototypes (From: Mike Schrag <email@hidden>)
 >Re: [Wonder-disc] OpenBase / boolean / ERPrototypes (From: "Ricardo J. Parada" <email@hidden>)

  • Prev by Date: Re: LDAP and EOF
  • Next by Date: Re: WOLips - Entity Modeler - reverse engineer from multiple scheme/user?
  • Previous by thread: Re: [Wonder-disc] OpenBase / boolean / ERPrototypes
  • Next by thread: Re: [Wonder-disc] OpenBase / boolean / ERPrototypes
  • Index(es):
    • Date
    • Thread