473,796 Members | 2,509 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Many to Many cOnFuSiOn

The trouble currently with 3 tables. I'm excluding non-relevant
fields...

tbl_users
PK_user_ID

tbl_developers
PK_developer_ID
FK_developer_us er_ID
FK_developer_pr oject_ID

tbl_projects
PK_project_ID
This is an application that manages users with 3 levels of access. All
users are in the users table and their access level is identified
there. The three levels are 1 (admin), 2 (developer), and 3 (client).
Currently my problem is with developers. I originally created the
developers table as a "bridge" table. What's backfiring that
intention is that there could be more than one developer for each
project, creating a many to many. How can I solve this?

Thanks!!

Feb 15 '06 #1
13 1887
the other john wrote:
The trouble currently with 3 tables. I'm excluding non-relevant
fields...

tbl_users
PK_user_ID

tbl_developers
PK_developer_ID
FK_developer_us er_ID
FK_developer_pr oject_ID

tbl_projects
PK_project_ID
This is an application that manages users with 3 levels of access.
All users are in the users table and their access level is identified
there. The three levels are 1 (admin), 2 (developer), and 3 (client).
Currently my problem is with developers. I originally created the
developers table as a "bridge" table. What's backfiring that
intention is that there could be more than one developer for each
project, creating a many to many.
Well, that is the reason for creating a bridge table: to resolve a
many-to-many relationship. Why do you say this is "backfiring "?
How can I solve this?

What do you need to solve?

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Feb 15 '06 #2
The there can be many developers for many projects, I don't know how to
solve this. As I said, I'm confused. Am I making this harder? Am I
not seeing something

Feb 15 '06 #3
the other john wrote:
The there can be many developers for many projects, I don't know how
to solve this. As I said, I'm confused. Am I making this harder?
Am I not seeing something


:-)
I guess so. I'm certainly not seeing something ...

What is the problem? Give us something specific to answer. What immediate
task are you having an issue with?

When you say you don't know how to "solve this", what do you mean by "this"?
I mean: you've got your database correctly designed to model the
many-to-many relationship. So there must be some other task that's confusing
you. What task is that?

Bob Barrows
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Feb 15 '06 #4
I'm trying to eliminate the many to many relationship. if more than
one developer can be assigned to more than one project that makes the
relationship between the project and developer tables many to many,
true?

Feb 15 '06 #5
the other john wrote:
I'm trying to eliminate the many to many relationship. if more than
one developer can be assigned to more than one project that makes the
relationship between the project and developer tables many to many,
true?

True.
Isn't that the correct relationship? Is that the problem? You want to have
only a single developer assigned to a project? If so, change the design to:

tbl_users
PK_user_ID

tbl_developers
PK_developer_ID
FK_developer_us er_ID

tbl_projects
PK_project_ID
FK_developer_ID

In this design, tbl_developers is no longer a "bridging" table: it is now a
"subclass" table. And there is now a 1-to-many relationship between
developers and projects

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Feb 15 '06 #6
actually I need there to "potentiall y" be more than one developer
assigned to a project. that's what's confusing me. If the developer
was unique to the project then this would be easier but with the
"potential" for more than one I don't know how to proceed.

Feb 15 '06 #7
the other john wrote:
actually I need there to "potentiall y" be more than one developer
assigned to a project.
So you need a many-to-many relationship. Your original design handles
this.What's the problem?
that's what's confusing me.
I'm sorry, but I just don't understand what's confusing you.
If the developer
was unique to the project then this
What do you mean by "this"?
would be easier but with the
"potential" for more than one I don't know how to proceed.


You "don't know how to proceed " with what? What is the next task you need
to perform that your confusion is preventing you from performing? Be
specific.

Bob Barrows

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Feb 15 '06 #8
I must not understand something here because I'm being as specific as I
can. I'm trying to "get rid" of the many-to-many relationship and
create, somehow, a one to many relationship (while still complying with
the "more than one developer" need) as M2M is not RDBM compliant, or in
short, not good.
the other john wrote:
actually I need there to "potentiall y" be more than one developer
assigned to a project.

So you need a many-to-many relationship. Your original design handles
this.What's the problem?

that's what's confusing me.

I'm sorry, but I just don't understand what's confusing you.

If the developer
was unique to the project then this

What do you mean by "this"?

would be easier but with the
"potential" for more than one I don't know how to proceed.

You "don't know how to proceed " with what? What is the next task you
need
to perform that your confusion is preventing you from performing? Be
specific.

Bob Barrows
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.

Feb 15 '06 #9
the other john wrote:
I must not understand something here because I'm being as specific as
I can. I'm trying to "get rid" of the many-to-many relationship and
create, somehow, a one to many relationship (while still complying
with the "more than one developer" need) :-)
You mean like getting a woman "almost pregnant"?
Well that is just not possible. You either have a 1-to-many relationship or
a many-to-many relationship. There is nothing in-between. If a project can
have more than one developer assigned to it, and a developer can be assigned
to multiple projects, then, by definition, you have a many-to-many
relationship. What is the problem?
as M2M is not RDBM compliant,
Excuse me????
Where in the world did you get this idea? A many-to-many relationship
resolved by a "bridge" or "link" table is certainly "RDBM compliant".
Show me the normalization rule that is broken by a M2M relationship ...
or in short, not good.


And what is "not good" about it? Using this model, you can easily get a list
of developers assigned to a specific project, right? And it's child's play
to get a list of projects assigned to a specific developer, right? What is
the problem?

--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Feb 15 '06 #10

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

Similar topics

4
2589
by: J-P | last post by:
Hi, I have a Python script interacting with a specialized C numerical library. The whole program does quite a lot of number crunching as should be running for a couple of hours. However, it always seems to run out of memory after maybe 40-45 minutes (I get a MemoryError from the python interpreter). I wanted to see what took that much memory so I printed a reference count (using sys.getrefcount()) and I was suprised to
4
2544
by: JMCN | last post by:
object invalid or no longer set - confusion of the recordset in access 2003. i am currently converting from access 97 to access 2003. majority of the codes converted over perfectly fine, though my recordset did not. i read from pasts posts that some references will not convert. so i tried to change the dao 3.51 reference to dao 3.6 in access 97. then i imported all of the objects into an access 2003. it did not work. so my second...
9
1601
by: Patrick Fisher | last post by:
Hi All If I Take DateFrom from DateTo in a 31 day month I get 30 days because 31-1=30, is there a way of getting the correct answer without having to us a lookup table? Patrick
10
3667
by: joelagnel | last post by:
hi friends, i've been having this confusion for about a year, i want to know the exact difference between text and binary files. using the fwrite function in c, i wrote 2 bytes of integers in binary mode. according to me, notepad opens files and each byte of the file read, it converts that byte from ascii to its correct character and displays
5
2990
by: Robert | last post by:
I am very new to .net and asp.net. I am trying to design an intranet page that has a SQL Server 2000 database. I understand how to connect to the data but am getting very confused on how to display, update and modify data in a one to many relationship. Is there any resource available that can show me how a web form looks when the data is in a one to many relationship. I've done work in MS Access and it was very easy using sub forms...
1
3181
by: Richard Lewis Haggard | last post by:
I'm having a problem with what appears to be some sort of confusion with references. I have a single solution with a dozen projects which has been working quite nicely for a while. The references between projects in the solution were established through project references, not by browsing to an assembly DLL. All of the projects are strongly named and use key files. Each project's AssemblyInfo.cs specifies the assembly version, where the...
16
2323
by: Martin Jørgensen | last post by:
Hi, Problem: ======== Some of my output functions are beginning to take pretty many arguments... I mean.... We're talking about 10-15 arguments :-) So I thought to myself, perhaps this is beginning to get out of hands if I continue to put in extra functionality in the (file-writing) output-functions....
26
2660
by: hide1713 | last post by:
HI I'm currently using Python. I find that a instance variable must confined with self, for example: class a: def __init__(self): self.aa=10 def bb(self): print self.aa # See .if in c++,I could use aa to change that variable
13
32150
by: mao | last post by:
Hi, if I set my body element width to be 100%, how many px value equal to this 100% width? In other words, <html> .... <body> ....
0
9680
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10456
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10174
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10012
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9052
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7548
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5575
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4118
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3731
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.