Re: Doing without object IDs
- From: "Ed Prochak" <edprochak@xxxxxxxxx>
- Date: 30 Jun 2006 05:07:01 -0700
First let me congratulate you on realizing that arbitrary ID's
(pseudokeys) in a database are essentially pointer values similar to
pointers in programing languages like C!
Pseudokeys have their uses, but they should be used carefully.
rixed wrote:
On 2006-06-29, Bob Stearns <rstearns1241@xxxxxxxxxxx> wrote:
Actually a time stamp of the beginning of the game between 'A' and 'B'
would uniquely identify the game unless you have two masters playing
simultaneous lightning boards between each other.
I though of that (this is how a PGN 'database' identifies a game : A, B,
date, and event - and round if applicable).
yes that is the more natural key.
But I already have a time stamp in the move table, so that the time stamp
of the game, being the time stamp of the first move, would be a mere
repetition.
Why timestamp the moves? Unless you are going to try to calculate the
time remaining on the players clock, it seem excessive. I do not know
any tournaments that have players record the time of their moves. Now
obviously you are setting up some online system, so you could record
this easily. But I still have to question why?
If you record time for each move, perhaps you should record merely
elapsed time.
Or, as there are always a first move in a game (a game that is
abandoned before the first move can not reasonably be called a game),
I store the first move in the game table, so that there are no
redundancy between the date of the game and the date of the first move.
the time of the game and the time of the move are not necessarily
redundant data. It depends on why you record that data. Consider: when
would you run a report that shows the time of each move? (where the
time is the relevant information) As a Chess player, i've never been
interested in when I made my moves. But I do still have notations from
a few games where it records where the game was played and when the
game was played (date, but no time).
What do you think ?
Consider how you will use the data. Consider writing a couple typical
queries. Ask your users, do they want that information? Collecting
information, just because you can, is seldom a good reason.
That's what I think.
Ed
.
- Follow-Ups:
- Re: Doing without object IDs
- From: rixed
- Re: Doing without object IDs
- References:
- Doing without object IDs
- From: rixed
- Re: Doing without object IDs
- From: Bob Stearns
- Re: Doing without object IDs
- From: rixed
- Doing without object IDs
- Prev by Date: Re: SQL Server 2005 help
- Next by Date: object mapping to database
- Previous by thread: Re: Doing without object IDs
- Next by thread: Re: Doing without object IDs
- Index(es):
Relevant Pages
|
|