On 09/feb/06, at 05:38, Kieran Kelleher wrote:

How does the NSDictionary "hints" argument in EOFetchSpecification constructor work?

IIRC, you have to create a dictionary like { CustomQueryExpressionHintKey = "SELECT * FROM BLAH…"; }. The EODatabaseContext will then use it to fetch data effectively bypassing the fetch spec's own qualifier and other options. From EODatabaseContext javadoc:
EODatabaseContext defines a hint for use with an EOFetchSpecification (EOControl) in the method objectsWithFetchSpecification. Named by the key CustomQueryExpressionHintKey, the hint's value is an SQL string for performing the fetch. The expression must query the same attributes in the same order that Enterprise Objects Framework would if it were generating the SELECT expression dynamically. If this key is supplied, other characteristics of the EOFetchSpecification such as isDeep, qualifier, and sortOrderings are ignored. In that sense, this key is more of a directive than a hint.

Hope this helps

--
Giorgio Valoti
--------------

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

This email sent to [email protected]

Reply via email to