home *** CD-ROM | disk | FTP | other *** search
- From: Bruce.Feist@f615.n109.z1.fidonet.org (Bruce Feist)
- Sender: Uucp@blkcat.UUCP
- Path: sparky!uunet!blkcat!Uucp
- Newsgroups: comp.databases
- Subject: Logical design experiences?
- Message-ID: <724514440.AA00000@blkcat.UUCP>
- Date: Wed, 16 Dec 1992 07:21:26 -0500
- Lines: 56
-
- Hi, Mark;
-
- g> Please tell me of any positive or negative experiences you
- g> have had with developing databases with or without quality logical
- g> designs. Any stories would be more than welcome. If you know of any
- g> studies along these lines, please let me know. Thank you very much.
-
- Ah, the tales I can tell... I can think of three offhand. Here goes...
-
- Story the First:
-
- Organizational units could have any *one* of three possible types of code
- associated with them. There are overlapping values between the codes (for
- instance, 'X' might be valid for both a type 1 code and a type 2 code). Users
- tend not to think about there being separate types codes, though.
-
- In an old design, there were *four* code fields: a generic one, plus one for
- each of the three types (only the correct one was to be filled out). Which one
- was filled out indicated the type of code; the 'generic' one was there, I
- believe to simplify indexing.
-
- I was asked to help in a redesign. I pointed out that the current design was a
- structure; what if a berserk program filled out *two* of the type-specific
- fields, or none at all? It would be better to store a single code value, along
- with an indicator specifying what type of code was being stored. The original
- designer explained that in practice that would never happen.
-
- I then looked at the data. It had *already* happened. My proposed change went
- through.
-
- Story the Second:
-
- Same system. Organizational units can have two addresses -- a home address and
- and a current one (they move around). This suggested to me that other addresses
- might be useful in the future -- possibly an address for a standard training
- site, for instance. I proposed normalizing the location information out into
- another table. The original designer explained that there was no way that more
- than these two locations would ever be required. The project manager called in
- a user later during the meeting; he mentioned in passing that they were thinking
- about storing a third type of location.
-
- Story the Third:
-
- Different portion of the same system; this happened in the personnel portion.
- Normalization resulted in many (call it 20) tables to describe personnel. For
- 'efficiency', the original designer (same fellow as above) decided to include a
- status flag in each of them; the idea was that this would speed up selection. In
- practice, it has turned out that queries almost invariably specify a single
- master table (possibly joined with others), which is where the status flag
- really belongs. So, there is minimal speedup in queries -- but their update
- program, which must frequently update the status flag, takes 12 hours or so to
- run -- roughly 20 times longer than necessary. As far as I know, the status
- flags are in synch from table to table -- but I wouldn't bet on it.
-
- Bruce
-
-