Hi, Matt,
Take a look at the EOQualifier JavaDoc and search for "Using
Selectors in Qualifier Expressions".
I think you'll find your answer there.
Regards,
Jerry
On Sep 3, 2006, at 10: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.
Can anyone provide a better debug message? I really don't understand
why I'm getting this error.
thanks,
matt
---
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'
---
code from 'State' object
public NSArray galleriesActive() {
EOQualifier qualifier =
EOQualifier.qualifierWithQualifierFormat("parentID = nil AND status =
1",null);
NSMutableArray EOArray = EOQualifier.filteredArrayWithQualifier(
galleries(), qualifier).mutableClone();
EOSortOrdering galleryOrdering =
EOSortOrdering.sortOrderingWithKey("name",
EOSortOrdering.CompareCaseInsensitiveAscending );
NSArray sortArray = new NSArray(galleryOrdering);
EOSortOrdering.sortArrayUsingKeyOrderArray(EOArray, sortArray);
return EOArray;
}
public NSArray galleriesWithOpeningPlusZeroDays(){
EOQualifier qualifier =
EOQualifier.qualifierWithQualifierFormat("hasOpeningPlusZeroDays =
'true'",null);
return EOQualifier.filteredArrayWithQualifier( galleriesActive(),
qualifier).mutableClone();
}
public boolean hasOpeningPlusZeroDays(){ return
(galleriesWithOpeningPlusZeroDays().count() > 0); }
_______________________________________________
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/jerrywwalker%
40gmail.com
This email sent to [EMAIL PROTECTED]
--
__ Jerry W. Walker,
WebObjects Developer/Instructor for High Performance Industrial
Strength Internet Enabled Systems
[EMAIL PROTECTED]
203 278-4085 office
_______________________________________________
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