
@Shadrack, unfortunately, I cannot allow the users to create the categories since, well, users never know what they really want. Secondly, at the end of it all, I want to create nice bar graphs comparing motorcycle and motor vehicle accidents. Since it will be running on MySQL, I am assuming that at some point I will have to do a COUNT() followed by GROUP BY category, unless there is an alternative to that. Another question, which is the best way to deal with accidents which span several categories? On Tue, Oct 25, 2011 at 11:27 AM, Shadrack Mwaniki < shadrack_mwaniki@yahoo.com> wrote:
Hi, The best approach is make it flexible and configurable Create a table called Accident Categories. Let the users define the categories themselves Then on the accidents table, link an accident with a category
Regards Shadrack
------------------------------ *From:* geoffrey gitagia <ggitagia@gmail.com> *To:* Skunkworks Mailing List <skunkworks@lists.my.co.ke> *Sent:* Tuesday, October 25, 2011 10:55 AM *Subject:* Re: [Skunkworks] Database design question
you are looking for one general category called "Incident" this will be your event where you can capture the above ....Borrowed from MSCRM ....if your oranisation would like they can adopt a CRM system ...cuts work by 50% percent :)
On Tue, Oct 25, 2011 at 10:29 AM, Peter Karunyu <pkarunyu@gmail.com>wrote:
Suppose you were designing a database to store accidents, and you had the need to categorize them, are the categories below sufficient? By accident here I mean non-intentional occurrences which lead to undesirable consequences...
1. Vehicle Accidents involving vehicles with at least 4 wheels
2. Cycles (is there a better name for this?) Vehicles with three wheels and less
3. Buildings
4. Infrastructure, e.g. bridges collapsing etc
5. Marine How do you differentiate someone drowning from a boat sinking?
6. Aircraft
7. Ordinance? Old military appliances that tend to explode?
8. Domestic Accidents which happen at home. But if a fire takes place at home, and a fire takes place at a factory, are these two different categories or should they be the same, or both?
9. Industrial
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
-- GG
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke
-- Regards, Peter Karunyu -------------------