![]() | |
![]() |
| | Thread Tools | Display Modes |
#11
| |||
| |||
|
#12
| |||
| |||
|
|
It's exactly what I'm doing.....I'm recording hits to an advertising engine, before they get to the media server. Some client players hit more than once before they connect, causing a duplicate entry. I just want to see it sorted out w/out the duplicates. I have the distribution server logs for accurate playback reporting, I'm only interested in seeing cleaned up hits. |
#13
| |||
| |||
|
|
(but the ID field is still a poor crutch for a possibly weak design.) hmmmm. i'd prefer to think of it as the table stores ALL hits to the table, but this particular data consumer only wants to see ONE. |
|
The way I think about it, your natural key would be the composite of all fields in the table; perhaps "natural", but certainly awkword. I like figital's solution. |
#14
| |||
| |||
|
|
My point is too many people immediately jump to ID fields as the PK. |
#15
| |||
| |||
|
|
"Ed Prochak" <edprochak (AT) gmail (DOT) com> wrote in message news:1141752316.933161.102260 (AT) i39g2000cwa (DOT) googlegroups.com... My point is too many people immediately jump to ID fields as the PK. That's certainly a good point. However, I've worked on projects in which the decision-makers wouldn't commit to _any_ combination of attributes that would uniquely identify the entity. There were always cases where the value in any column could be either non-unique, or else have no value specified (i.e. NULL). Neither would they commit to any attributes that could be reasonably stable and unchanging (though I understand that this is not strictly necessary for a key). |
|
So in those kinds of situations, I felt I had to create pseudokeys to have any chance of the application working. Even if we know the best practices for database modeling, the project on which we are working may have constraints that don't allow us to follow those best practices. Regards, Bill K. |
![]() |
| Thread Tools | |
| Display Modes | |
| |