• 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: Using an auto incremented NSNumber as attribute in a NSManagedObject
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using an auto incremented NSNumber as attribute in a NSManagedObject


  • Subject: Re: Using an auto incremented NSNumber as attribute in a NSManagedObject
  • From: Joshua Preston <email@hidden>
  • Date: Thu, 6 Mar 2008 17:32:59 -0500

Chris,

The short answer is for quick look ups. My application creates a new managed object which represents a new "issue". When the person done with the entry completes it, they should be issued a "tracking number". For reasons ubiquitous with telephone support, I am attempting to only utilize numeric values. So for example, I create a new ticket, I should be able to look it up by a human readable index using very low tech means--think telephone keypad...

Now I won't claim to be the expert on this subject, but it did seem to me that the indexes (keys) created by core data would probably not use a simple integer for key look ups, or allow me to specify a range of valid numbers. I mean, for ease of use, I was going to start my range in the millions to keep a consistent length of the "reference id".

Regards,

Joshua Preston
email@hidden




On Mar 6, 2008, at 4:56 PM, Chris Hanson wrote:

On Mar 6, 2008, at 1:05 PM, Joshua Preston wrote:

I am however having problems finding information regarding auto incremented attributes, namely an NSNumber attribute.

What do you want to do with this? Core Data manages primary & foreign keys for you via object IDs and relationships, so you don't have to do anything with those yourself. (And those are the typical uses of auto-incrementing fields or sequences.)


-- Chris


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Using an auto incremented NSNumber as attribute in a NSManagedObject
      • From: "Kyle Sluder" <email@hidden>
References: 
 >Using an auto incremented NSNumber as attribute in a NSManagedObject (From: Joshua Preston <email@hidden>)
 >Re: Using an auto incremented NSNumber as attribute in a NSManagedObject (From: Chris Hanson <email@hidden>)

  • Prev by Date: Re: Using an auto incremented NSNumber as attribute in a NSManagedObject
  • Next by Date: Presumably iphone does Objective-C 2.0?
  • Previous by thread: Re: Using an auto incremented NSNumber as attribute in a NSManagedObject
  • Next by thread: Re: Using an auto incremented NSNumber as attribute in a NSManagedObject
  • Index(es):
    • Date
    • Thread