Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Mike Yearwood
  Where is Mike Yearwood?
 Toronto
 Canada
 Mike Yearwood
 To: Andy Kramek
  Where is Andy Kramek?
 Hot Springs Village
 Arkansas - United States
 Andy Kramek
 Tags
Subject: RE: Primary Key
Thread ID: 143107 Message ID: 143396 # Views: 38 # Ratings: 0
Version: Visual FoxPro 9 Category: Databases, Tables and SQL Server
Date: Tuesday, August 28, 2007 2:33:15 PM         
   


> >
> > A PK must uniquely identify the row. Nowhere is it written what the nature of the PK must be.
>
> I absolutely agree!- the only 'rule' is that is unique within the table - and while I would normally use a surrogate integer as a primary key that is by no means a requirement and is, again, just my preference based on 20+ years database experience including virtually all mainframe, mid-range and PC databases.

We agree on something! :)

Yet, why do people insist on saying how long they've been in the industry? Does a person that smoked for 20 years mean they're doing the right thing? Not in the least. I've met people with 15, and 20 years of experience that are doing really bad things. I have almost 30 years of experience on all of these things too. Besides that, I'm only 42. I've spent much of my career adapting to changing trends. Yes, I got started at 11 (almost 12) and had my first real IT job at 13.

> > Those that wrote the docs seem to feel it's a true GUID.
>
> Yeah I am sure they do. Microsoft is notorious for re-defining accepted terms to mean whatever they want it to be - shades of Humpty-Dumpty in "Alice in Wonderland" who says "A word means just what I choose it to mean, neither more nor less"

Things evolve or they stagnate. The attempt to add a sequential component to the guid is evolution.

> Index-sequentiality is not any part of the definition of a GUID by any accepted term - in fact the essence of a GUID is its randomness - which simply cannot be true if they are sequential!
>
> I am sure you will agree that by enforcing sequentiality you remove the degree of freedom guaranteed by the randomness which is integral to the definition of a UUID, and hence a GUID.
> The risk is that by generating sequential 'GUIDs' you may either inadvertently arrive at a value that arises randomly from some other source combination, or simply exhaust your supply of possible values long before 3400 AD :)

Removing the network specific information from a UUID reduces its randomness so that we are warned that two computers can generate the same UUID. Nothing is perfect and things have to be adjusted to better suit the times.

Please see the docs on UuidCreateSequential

http://msdn2.microsoft.com/en-us/library/aa379322.aspx

specifically the line

"Computers with ethernet/token ring addresses generate UUIDs that are guaranteed to be globally unique."

Mike Yearwood
www.foxridgesoftware.com
President: Toronto Ontario FoxPro User's Group

ENTIRE THREAD

Primary Key Posted by Aaron Hathaway @ 8/24/2007 10:25:32 PM
RE: Primary Key Posted by Borislav Borissov @ 8/24/2007 10:46:52 PM
RE: Primary Key Posted by Aaron Hathaway @ 8/24/2007 11:09:39 PM
RE: Primary Key Posted by Ken Murphy @ 8/25/2007 1:47:10 AM
RE: Primary Key Posted by Barbara Peisch @ 8/25/2007 5:01:14 AM
RE: Primary Key Posted by Mike Yearwood @ 8/26/2007 2:02:59 AM
RE: Primary Key Posted by Andy Kramek @ 8/27/2007 1:01:44 PM
RE: Primary Key Posted by Mike Yearwood @ 8/27/2007 3:37:30 PM
RE: Primary Key Posted by Andy Kramek @ 8/27/2007 5:57:08 PM
RE: Primary Key Posted by Mike Yearwood @ 8/27/2007 7:55:38 PM
RE: Primary Key Posted by Andy Kramek @ 8/27/2007 8:31:58 PM
RE: Primary Key Posted by Mike Yearwood @ 8/28/2007 2:33:15 PM
RE: Primary Key Posted by Andy Kramek @ 8/28/2007 2:48:25 PM
RE: Primary Key Posted by Ken Murphy @ 8/28/2007 3:48:57 PM
RE: Primary Key Posted by Andy Kramek @ 8/28/2007 5:06:25 PM
RE: Primary Key Posted by Ken Murphy @ 8/28/2007 6:03:54 PM
RE: Primary Key Posted by Andy Kramek @ 8/28/2007 9:10:24 PM
RE: Primary Key Posted by Ken Murphy @ 8/28/2007 10:48:19 PM
RE: Primary Key Posted by Andy Kramek @ 8/29/2007 12:41:37 PM
RE: Primary Key Posted by Ken Murphy @ 8/29/2007 12:58:20 PM
RE: Primary Key Posted by Mike Yearwood @ 8/29/2007 7:49:54 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/25/2016 7:09:30 PM
RE: Primary Key Posted by Tore Bleken @ 7/25/2016 8:03:30 PM
RE: Primary Key Posted by Hugo Ranea @ 8/29/2007 9:34:10 PM
RE: Primary Key Posted by Daniel Hofford @ 8/29/2007 11:46:07 PM
RE: Primary Key Posted by Mike Yearwood @ 7/24/2016 1:53:22 PM
RE: Primary Key Posted by Benny Thomas @ 7/24/2016 2:30:24 PM
RE: Primary Key Posted by Mike Yearwood @ 7/24/2016 3:20:23 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/25/2016 7:16:41 PM
RE: Primary Key Posted by Mike Yearwood @ 7/25/2016 8:49:05 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/25/2016 7:04:07 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/25/2016 6:59:58 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/25/2016 7:00:06 PM
RE: Primary Key Posted by Koen Piller @ 7/25/2016 11:37:27 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/26/2016 8:01:52 PM
RE: Primary Key Posted by Mike Yearwood @ 7/26/2016 8:59:17 PM
RE: Primary Key Posted by Gene Wirchenko @ 7/27/2016 7:02:39 PM
RE: Primary Key Posted by Paul Gibson @ 7/27/2016 12:21:25 PM