On Sep 3, 2006, at 4:42 PM, Matt Kime wrote:

I have an object with the code below. When I try this search from a
WOComponent - EOQualifier.qualifierWithQualifierFormat ("hasOpeningPlusZeroDays
= 'true'" ,null); I get the error below. I don't understand why I'm
getting this error. hasOpeningPlusZero days is clearly reachable.

java.lang.IllegalStateException: sqlStringForKeyValueQualifier:
attempt to generate SQL for
com.webobjects.eocontrol.EOKeyValueQualifier (hasOpeningPlusZeroDays =
'true') failed because attribute identified by key
'hasOpeningPlusZeroDays' was not reachable from entity 'State'

The exception states that your code is attempting to generate SQL and that the key "hasOpeningPlusZeroDays" was not reachable from entity "State". I don't know what your eomodel looks like, but it appears that hasOpeningPlusZeroDays is a method in State.java rather than an attribute of the State entity; i.e., it does not map to a database column. And the code that is causing this exception appears to be qualifying against the database (therefore, the SQL generation) rather than in memory. If my assumptions are true, then there's no "hasOpeningPlusZeroDays" attribute in the "State" entity, so hasOpeningPlusZeroDays is unreachable.

Aloha,
Art

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to archive@mail-archive.com

Reply via email to