473,396 Members | 1,599 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,396 software developers and data experts.

good practise (2)

Hi again,

I need another good practise advice.

Everybody (100 persons) in our compagny manages one or more projects. Each
projects needs two tables: table 'project' (general information), table
'projectdetails' (details of projects) and one or more result tables (one
per project) like 'projectresult1', 'projectresult2' etc ...
One project needs more or less 300 records with 6 fields (with size:
nvarchar(200) average)). Nothing special.

There are more scenarios possible (using sql server 2005 express):

1) one database ('project') containing one table 'project', one table
'projectdetails' and several tables 'projectresultX', common to all
projectmanagers.

2) one database ('project') containing for each projetcmanager a table
'project_managerID', a table 'projectdetails_ managerID' and several tables
'projectresultXmanagerID'.

3) for each projectmanager a database 'projectmanager_ID' containing one
table 'project', one table 'projectdetails' and several tables
'projectresultX'.

I must say: the databases and tables are all created programmatically in
code-behind when the projectmanager starts the application the first time
only.

So which scenario woul be the best generally spoken?

Thanks for your advice.
Chris
Jul 11 '07 #1
3 1327
Chris
1) Table for Project Managers
2) Table for Projetcs (projectid ,managerid.....)
3) Table for Prioject Details
4) Table for Project_Results (junction table (many-to-many relationship))
(projectid, project_result_id ......) Could be PK on projectid,
project_result_id


"Chris" <kn*@shdv.sdwrote in message
news:OO*************@TK2MSFTNGP06.phx.gbl...
Hi again,

I need another good practise advice.

Everybody (100 persons) in our compagny manages one or more projects.
Each projects needs two tables: table 'project' (general information),
table 'projectdetails' (details of projects) and one or more result tables
(one per project) like 'projectresult1', 'projectresult2' etc ...
One project needs more or less 300 records with 6 fields (with size:
nvarchar(200) average)). Nothing special.

There are more scenarios possible (using sql server 2005 express):

1) one database ('project') containing one table 'project', one table
'projectdetails' and several tables 'projectresultX', common to all
projectmanagers.

2) one database ('project') containing for each projetcmanager a table
'project_managerID', a table 'projectdetails_ managerID' and several
tables 'projectresultXmanagerID'.

3) for each projectmanager a database 'projectmanager_ID' containing one
table 'project', one table 'projectdetails' and several tables
'projectresultX'.

I must say: the databases and tables are all created programmatically in
code-behind when the projectmanager starts the application the first time
only.

So which scenario woul be the best generally spoken?

Thanks for your advice.
Chris


Jul 11 '07 #2
On 11 Jul, 15:28, "Uri Dimant" <u...@iscar.co.ilwrote:
Chris
1) Table for Project Managers
2) Table for Projetcs (projectid ,managerid.....)
3) Table for Prioject Details
4) Table for Project_Results (junction table (many-to-many relationship))
(projectid, project_result_id ......) Could be PK on projectid,
project_result_id

"Chris" <k...@shdv.sdwrote in message

news:OO*************@TK2MSFTNGP06.phx.gbl...
Hi again,
I need another good practise advice.
Everybody (100 persons) in our compagny manages one or more projects.
Each projects needs two tables: table 'project' (general information),
table 'projectdetails' (details of projects) and one or more result tables
(one per project) like 'projectresult1', 'projectresult2' etc ...
One project needs more or less 300 records with 6 fields (with size:
nvarchar(200) average)). Nothing special.
There are more scenarios possible (using sql server 2005 express):
1) one database ('project') containing one table 'project', one table
'projectdetails' and several tables 'projectresultX', common to all
projectmanagers.
2) one database ('project') containing for each projetcmanager a table
'project_managerID', a table 'projectdetails_ managerID' and several
tables 'projectresultXmanagerID'.
3) for each projectmanager a database 'projectmanager_ID' containing one
table 'project', one table 'projectdetails' and several tables
'projectresultX'.
I must say: the databases and tables are all created programmatically in
code-behind when the projectmanager starts the application the first time
only.
So which scenario woul be the best generally spoken?
Thanks for your advice.
Chris- Hide quoted text -

- Show quoted text -
As Uri suggested, having multiple projectresults tables is seldom the
best design, however the wording of your question was a little
unclear:

<quote>
table 'projectdetails' (details of projects) and one or more result tables
(one per project) like 'projectresult1', 'projectresult2' etc ...
</quote>

Do you mean that for each project there is a single results table, but
that each manager could have more than 1 results table (due to the
fact that they can run more than 1 project)?
If this is the case, then you should not need a many-to-many
relationship as the relationship between project and projectresult is
only one-to-many (projectid column could be added to the
projectresults table and allow multiple references to the same
project).

If (as Uri assumed) 1 project could require multiple projectresults
tables then you will need a junction table to facilitate the many-to-
many relationship

J

Jul 11 '07 #3
Thanks for replying.
The answer to this is yes:
"Do you mean that for each project there is a single results table, but
that each manager could have more than 1 results table (due to the
fact that they can run more than 1 project)?"

The tables 'results' are all diffeent (different fields).

To summarize:
one database 'project' (and not a database per manager?)
one table 'managers' for all managers and projects'
one table projectdetails for all managers and all projects
several tables 'results' for each project of each manager

This is ok?

What's the drawback of the two other scenarios?
one common database and for each manager one table 'project', 'details'
'results
one database for each manager

Thanks

<jh******@googlemail.comschreef in bericht
news:11**********************@k79g2000hse.googlegr oups.com...
On 11 Jul, 15:28, "Uri Dimant" <u...@iscar.co.ilwrote:
>Chris
1) Table for Project Managers
2) Table for Projetcs (projectid ,managerid.....)
3) Table for Prioject Details
4) Table for Project_Results (junction table (many-to-many relationship))
(projectid, project_result_id ......) Could be PK on projectid,
project_result_id

"Chris" <k...@shdv.sdwrote in message

news:OO*************@TK2MSFTNGP06.phx.gbl...
Hi again,
I need another good practise advice.
Everybody (100 persons) in our compagny manages one or more projects.
Each projects needs two tables: table 'project' (general information),
table 'projectdetails' (details of projects) and one or more result
tables
(one per project) like 'projectresult1', 'projectresult2' etc ...
One project needs more or less 300 records with 6 fields (with size:
nvarchar(200) average)). Nothing special.
There are more scenarios possible (using sql server 2005 express):
1) one database ('project') containing one table 'project', one table
'projectdetails' and several tables 'projectresultX', common to all
projectmanagers.
2) one database ('project') containing for each projetcmanager a table
'project_managerID', a table 'projectdetails_ managerID' and several
tables 'projectresultXmanagerID'.
3) for each projectmanager a database 'projectmanager_ID' containing
one
table 'project', one table 'projectdetails' and several tables
'projectresultX'.
I must say: the databases and tables are all created programmatically
in
code-behind when the projectmanager starts the application the first
time
only.
So which scenario woul be the best generally spoken?
Thanks for your advice.
Chris- Hide quoted text -

- Show quoted text -

As Uri suggested, having multiple projectresults tables is seldom the
best design, however the wording of your question was a little
unclear:

<quote>
table 'projectdetails' (details of projects) and one or more result
tables
(one per project) like 'projectresult1', 'projectresult2' etc ...
</quote>

Do you mean that for each project there is a single results table, but
that each manager could have more than 1 results table (due to the
fact that they can run more than 1 project)?
If this is the case, then you should not need a many-to-many
relationship as the relationship between project and projectresult is
only one-to-many (projectid column could be added to the
projectresults table and allow multiple references to the same
project).

If (as Uri assumed) 1 project could require multiple projectresults
tables then you will need a junction table to facilitate the many-to-
many relationship

J

Jul 11 '07 #4

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

Similar topics

7
by: Coder Droid | last post by:
I decided to run some code with errors set to E_ALL, just to see what I would run across. It caught a few things, but 90% or better of the messages were of the 'undefined' kind: PHP Notice: ...
15
by: Randall Smith | last post by:
I've been programming in Python for about 2 years. I think it offers the best combination of simplicity and power of any language I have explored. As I write more and larger and complex programs,...
1
by: ===Steve L.=== | last post by:
I'm new to vb studio .net and sql2k, and wondered if any one know any good articles on the subject? such as the best practices and configuration for the database connection and security model....
12
by: alex | last post by:
Hi, I was just wandering which one is correct, better, or better programming practice? //Case #1 public class Main { ClassA a = new ClassA(); a.Value = "some value";
1
by: trebor | last post by:
I'm learning dotNet, although I first learned programming back in the days when structured programming was all the rage. In both my books and courses, I've seen something like this: Public Class...
5
by: bloukopkoggelmander | last post by:
Hi All Just a question about good Access design. I have a form which displays some information from different tables through comboboxes(which the user selects) and textboxes. There are then...
0
by: sri5739 | last post by:
Hi All, Could anyone please let me know how the best way to prepare for MCAD certifications for .net and whr can i get the practise papers and the questions for it. This will really help me ..Thanx...
0
by: sri5739 | last post by:
Hi All, Can anyone help in getting me the .net MCAD practise exams link and practise question papers .. this will really help me .. thanks a lot in advance
9
by: =?Utf-8?B?RXZlcnQ=?= | last post by:
Does anybody have a good example/guide for using LINQ in a layered architecture with maybe WCF? Thanks in advance, Evert
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.