473,385 Members | 1,468 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Database design question

I'm in the process of designing a database and would like some
suggestion on how to architect it.

I have 3 'objects', frequency, task, skill.

For each task there is a frequency however for some tasks there are a
number of different skills, each of which have different frequencies,
so, for example, imagine frequencies being time in minutes. Each task
has to be done a certain number of times but certain tasks have varied
skill levels and each skill level has different frequencies associated
with it.

Task 1, Freq 5min
Task 2, Freq 10min
Task 3, Skill 1, Freq 5min
Task 3, Skill 2, Freq 15min
Task 4, Skill 1, Freq 10min
Task 4, Skill 2, Freq 15min
Task 4, Skill 3, Freq 20min

The problems is that the freq / skill is dependent on the task. I'm
having trouble deciding how to build this database.

I could just hard code the Tasks/Skill in a table so that I have

TaskID PK
Task
Freq

and have records like:

1 Task1 5
2 Task2 10
3 Task3Skill1 5
4 Task3Skill2 15

but I don't like it because it is not easily maintained - in case
freq/skills change.

Does anyone have any ideas. The important information is the
frequency as it will be used to build timetables.
Jul 20 '05 #1
1 3594
>> I have 3 'objects', frequency, task, skill. <<

Basic question - in your business model are these separate entities or
attributes of an entity? What are the dependencies among them? The answer to
these questions lay the foundation for the table design.
I could just hard code the Tasks/Skill in a table ... <<


That violates 1NF (assuming tasks & skills are different attributes) and
based on my interpretation of your requirements would cause an update/delete
anomaly. Generally database design cannot be accomplished using Newsgroup
responses since it requires a comprehensive understanding of your underlying
business model, rules & requirements. However, based on a series of
assumptions, here is one way of SQL representation :

CREATE TABLE Tasks (
Task_id INT NOT NULL PRIMARY KEY,
Details VARCHAR(30) NOT NULL,
....);

CREATE TABLE Skills (
Skill_id INT NOT NULL PRIMARY KEY,
Decription VARCHAR(40) NOT NULL,
...);

CREATE TABLE TaskSkills (
Task_id INT NOT NULL
REFERENCES Tasks(Task_id),
Skill_id INT NOT NULL
REFERENCES Skills(Skill_id),
Freq INT NOT NULL
PRIMARY KEY(Task_id, Skill_id));

--
- Anith
( Please reply to newsgroups only )
Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Lefevre, Steven | last post by:
Hey folks - Thanks to everyone who gave input to my concerns. Of course, we don't intend to have the mysql port open to the world. We will have Apache/PHP connect on a unix socket, or to another...
2
by: Josh McFarlane | last post by:
If this is not the right place to post this, I apologize. I've taken over work for a few utility programs for a collection of database / raw files. All the programs but one read from the files,...
5
by: Don Vaillancourt | last post by:
Hello all, Over the years as I design more database schemas the more I come up with patterns in database design. The more patterns I recognize the more I want to try to design some kind of...
29
by: MP | last post by:
Greets, context: vb6/ado/.mdb/jet 4.0 (no access)/sql beginning learner, first database, planning stages (I think the underlying question here is whether to normalize or not to normalize this...
12
by: nyathancha | last post by:
Hi, I have a question regarding best practices in database design. In a relational database, is it wise/necessary to sometimes create tables that are not related to other tables through a...
1
by: arrival123 | last post by:
Hello, I'm currently trying to decide on a database design for tags in my web 2.0 application. The problem I'm facing is that I have 3 separate tables i.e. cars, planes, and schools. All three...
10
by: ARC | last post by:
Hello all, General question for back-end database that has numerous date fields where the database will be used in regions that put the month first, and regions that do not. Should I save a...
4
by: dgleeson3 | last post by:
Hello all I am creating a VB.Net distributed SQL server 2005 application. Each computer in the system has a database with a table of users and their telephone numbers. Each computer has a...
0
by: David | last post by:
Hi list. I have a few database-related questions. These aren't Python-specific questions, but some of my apps which use (or will use) these tables are in Python :-) Let me know if I should ask...
10
by: Les Desser | last post by:
In article <fcebdacd-2bd8-4d07-93a8-8b69d3452f3e@s50g2000hsb.googlegroups.com>, The Frog <Mr.Frog.to.you@googlemail.comMon, 14 Apr 2008 00:45:10 writes Not sure if I quite follow that. 1....
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.