Re: Ad-hoc Core Data queries ?
Re: Ad-hoc Core Data queries ?
- Subject: Re: Ad-hoc Core Data queries ?
- From: mmalcolm crawford <email@hidden>
- Date: Fri, 4 Nov 2005 08:44:54 -0800
On Nov 4, 2005, at 8:14 AM, Peter Raul wrote:
I have a lot of Core Data files, mostly in binary format. Now I'm
looking for a tool to query these "databases" interactively.
Something like the openisql SQL interpreter we have in Openbase,
but working at the Core Data level. Is there such a tool ?
I'm not aware of one, but it shouldn't be too difficult to write.
You need to create a Core Data stack using the appropriate model (you
could specify it as a commandline parameter), then you ask the user
for the name of an entity and optionally a predicate (which you
create using predicateWithFormat:). You might also allow sort
orderings. You then create a fetch request and return the result.
Rinse. Repeat.
Most of the basic code is in <http://developer.apple.com/
documentation/Cocoa/Conceptual/CoreDataUtilityTutorial/index.html>.
mmalc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden