• 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: Globally unique IDs
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Globally unique IDs


  • Subject: Re: Globally unique IDs
  • From: Alexander Spohr <email@hidden>
  • Date: Fri, 6 Feb 2004 23:05:30 +0100

in fact apple encourages you to use unique pks. i forgot where, but there is some document explaining how to do it with eof. they use time and machine ids and someting. i think i remeber 80 bit or 80 byte...

googling for "eomodeler unique primary key" finds:

 Adaptor-Generated Primary Key

In EOF's default primary key mechanism, the EOAdaptorChannel generates the primary keys. It collaborates with the database server to maintain a linear sequence of nonrepeating primary keys per entity. The primary key attribute must not be a class property. If the type of the primary key attribute is a 12-byte NSData, EOF generates unique primary keys without going to the database.

not sure if that's what your'e looking for :)

	atze


Am 06.02.2004 um 19:45 schrieb Colin O'Brien:

Hi,

we are working on a new system, where we will be moving data between different databases.
This will require objects with a simple ID that is globally unique.
It seems the automatic private key mechanism in WO only provides unique keys within a single database.
It seems we could get a truly unique ID using VMID.
It further seems we could create our own "PK's" in awakeFromInsertion.


The questions then would be
* is there going to be a noticeable performance hit using VMID's (40 bytes) compared to the more typical int?
more concerned about retrieval performance than update performance


* would it be better to use the built-in PK system and have a separate column for the VMID?
particularly thinking about how relationships might work


We are planning on using MySQL.
We looked at both MySQL and PostgreSQL and while PostgreSQL seems the better database system, MySQL seems better supported in WO.


Thanks for any help
Colin
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Globally unique IDs
      • From: David Teran <email@hidden>
References: 
 >Globally unique IDs (From: "Colin O'Brien" <email@hidden>)

  • Prev by Date: Re: WebObjects and linked CSS.
  • Next by Date: JavaMail in WO
  • Previous by thread: Re: Globally unique IDs
  • Next by thread: Re: Globally unique IDs
  • Index(es):
    • Date
    • Thread