• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Core Data: How do you count records in a persistent store?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core Data: How do you count records in a persistent store?


  • Subject: Re: Core Data: How do you count records in a persistent store?
  • From: mmalcolm crawford <email@hidden>
  • Date: Sun, 2 Apr 2006 12:21:45 -0700


On Apr 2, 2006, at 11:16 AM, Frederick C. Lee wrote:

How do you count (or determine empty) data from a persistent store (table)?

Execute a fetch for the entity in which you're interested, and count the returned array.

I've been trying to use the '@count' qualifier to determine if I have data
in a particular MO entity:
(gdb) po [[[[[managedObjectContext persistentStoreCoordinator]
managedObjectModel] entities] objectAtIndex:6] valueForKey:@"name.@count"]


It's not clear why you would try doing this?

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


References: 
 >Core Data: How do you count records in a persistent store? (From: "Frederick C. Lee" <email@hidden>)

  • Prev by Date: Re: Accessing the underlying managed object, from a controller
  • Next by Date: Re: Extracting file name & path from NSOpenPanel
  • Previous by thread: Core Data: How do you count records in a persistent store?
  • Next by thread: Extracting file name & path from NSOpenPanel
  • Index(es):
    • Date
    • Thread