Relational Thoughts

padlocked17

Registered User.
Local time
Today, 04:06
Joined
Aug 29, 2007
Messages
275
I've got a db I'm working on that will generate training reports for individuals. I've got a table that has a basic template consisting of a paragraph of text for each section of the report. Would I be violating the rules of a relational db if I took and copied that paragraph to a record for each member being trainined and receiving a training report. The issue is that each description for each person, while based on a template, may need to be altered/changed for that particular individual.

Thanks for the thoughts!
 
While some people may claim it violates some kind of normalization rule I think it sounds like a good method considering what you would have to do otherwise - :)
 
Thanks Ken. I really couldn't think of a simple solution that would circumvent the need to duplicate these entries for each member, I just wanted to make sure I wasn't missing something obvious. Thanks for the help!
 
It seems a gray area to me and other aspects need to be considered. Let's say the text was something like a long contract, like 2 or 3 pages long. And most of them were exactly the same but every now an then one needed some alterations. Within say 10k records where 20 were custom you would want to save the entire original contract 9980 times along with the 20 custom versions. In that case maybe you would design the system to reference a standard contract as a default while having the ability to store a custom version if required.

In this case you are only storing a paragraph (hopefully not very long), so storing a potential duplicate of the original multiple times kind of violates a normalization rule but I think I would still set it up like you have it and see how it works. Unless of course the paragraph is real long or you're going to have hundreds of thousands of records...
 
No that's the kicker. I anticipate at the most, there will be 5000k records at any given time. I'll be incorporating an "auto-purge" feature that deletes records after a certain amount of time. It just seemed like overkill to create a feature that would use a default, only to then create a copy if the end user wanted to edit the field. I guess realistically it wouldn't take too long to work that in, but it's one of those features that for the size of the DB I'm not too concerned.

Thanks for the recommendations however. It's always good to hear what you pros think of what I'm cranking out.
 
Just my opinion but I try and never delete records. Rather moving them to an alternate archive database table. I've gotten kudos for providing historical busness information based on records long forgotten about by the end users...
 
Awesome. I may just incorporate that into the db. Really not a bad idea at all. Thanks!
 

Users who are viewing this thread

Back
Top Bottom