Re: Finding managed objects by URI representation

2010-04-05 Thread Gideon King
You know you might just be right. The core problem was that I was using the value that I had generated as my reference object, because of my lack of understanding about it needing to be consistent for a particular managed object, but different for different objects (even if they had been loaded

Re: Finding managed objects by URI representation

2010-04-05 Thread Sean McBride
On Sun, 4 Apr 2010 23:14:20 +1000, Gideon King said: >I have some queries that used to look up objects based on an elementID >attribute, which used to be my unique identifier for objects, created >when the objects were inserted or loaded. I use this pattern also. >I am now moving away from that

Re: Finding managed objects by URI representation

2010-04-05 Thread Ben Trumbull
On Apr 5, 2010, at 8:18 AM, Gideon King wrote: > On 05/04/2010, at 6:51 AM, Ben Trumbull wrote: > >> No, this is going the wrong way. The objectID is the object's identity in >> the persistent store (e.g. primary key). You don't need to store pieces of >> it somewhere else. >> >> NSPredicat

Re: Finding managed objects by URI representation

2010-04-05 Thread Gideon King
On 05/04/2010, at 6:51 AM, Ben Trumbull wrote: > No, this is going the wrong way. The objectID is the object's identity in > the persistent store (e.g. primary key). You don't need to store pieces of > it somewhere else. > > NSPredicate *predicate = [NSPredicate predicateWithFormat:@"self ==

re: Finding managed objects by URI representation

2010-04-04 Thread Ben Trumbull
> I have some queries that used to look up objects based on an elementID > attribute, which used to be my unique identifier for objects, created when > the objects were inserted or loaded. I am now moving away from that and using > the standard managed object IDs and reference objects. > > So I

Finding managed objects by URI representation

2010-04-04 Thread Gideon King
I have some queries that used to look up objects based on an elementID attribute, which used to be my unique identifier for objects, created when the objects were inserted or loaded. I am now moving away from that and using the standard managed object IDs and reference objects. So I used to do