small medium large xlarge

Back to: All Forums  Core Data
Code_monkey_pragsmall
06 Feb 2010, 16:10
Fernando López (6 posts)

Dear Marcus,

On page 62 you recommend to initialize the @managedObjectModel@ with @initWithContentOfURL:@. Instead, the Xcode template on OS X 0.6 uses @mergedModelFromBundles@. Your change fails on page 71 as with versioning the file @DataModel.mom@ is moved to the directory @DataModel.momd@. Please, explains this problem in the net version of your fantastic book.

Mark-townsend_pragsmall
12 Feb 2010, 19:47
Mark Townsend (3 posts)

I’d like to know this answer as well. I keep getting an exception now in my managedObjectModel method that says:

Can’t merge models with two different entities named ‘Recipe’

Cheers, Mark

Avatarsmall_pragsmall
12 Feb 2010, 21:59
Marcus S. Zarra (284 posts)

Do a clean all on the project and then build it. Your build has the old compiled mom file still hanging around. Doing a clean will delete the old binary from the build directory.

Mark-townsend_pragsmall
13 Feb 2010, 03:49
Mark Townsend (3 posts)

That was it. Thanks Marcus! Great topic for a book. I used to use EOF back in the day. Really wish Apple didn’t kill it. But Apple doesn’t seem to want to really get into the enterprise market. WebObjects still lives on in Java, but I don’t know any companies outside of Apple who are using it.

You must be logged in to comment