• # How to make Relations for Instructor Schedule(one to many and many to many between tables)

Problem

How to make database design for Instructor Schedule(only relations between every table and other one to many AND Many to Many)

Tables already created but relation not make (Section,Class,Instructor,Courses,Student)

I need to make Tables Relation for Instructors schedule working in Training center give courses for Microsoft products

as ACCESS ,EXCEL,C#,SQL as following

* Training center Have more instructors .

* Every instructor give more courses in ACCESS ,EXCEL,C#,SQL weekly from Sunday to Thursday .

* Every instructor give Courses ACCESS ,EXCEL,C#,SQL in more classes inside Training center .

*Training center have 10 classes and every courses can given in more classes within week .

*Every courses ACCESS ,EXCEL,C#,SQL can given by more instructor .

*Every instructor give more sections .

* Section mean group of student every group of student classified to A,B,C,D,E,F.

* Every section can given by more instructor within week .

* Every section can given more courses in week .

* Every section can get more courses in more classes .

So that i need to know

Instructor Michel give Courses C# And SQL from time 2 to time 4 Every Sunday And Wednesday weekly in class A1 And B1 And C1

For section A And B and C And D (Relation between each table and others)
• I think your relation would be as follows
1 Training center Has many instructors .
1 Inst has many courses
1 training center has many classes
1 inst teach to many student sections
M inst teach to many student sections
Hope it helps

Thanks
Koolprasd2003
Editor, DotNetSpider MVM
Microsoft MVP 2014 [ASP.NET/IIS]

• Hi,

Initially start to work with table relation, we need to start with the Pseudo code.
Because if you consider all the problems in single tables you wont come to a solution or a conclusion.
So first understand the following things,

How many tables needed
How many relationships we are planning
How the table A is mapped to table B
Which is consider as a Primary Key in table A and which is mapped with table B

Once we are clear with all the above question we individually start creating table one by one.
While creating like that we might get the issue with Dependencies, Like 1NF, 2NF and 3NF problems because we are creating in the expansion matter. Once all the tables are created and mapped then we start implementing the Normalization to reduce the dependencies.

Thanks,
Mani

• this is my scheduled for instructor michel i make design for it
i attached with message

Delete Attachment

• Here is code snippet to create procedure to make relationship between one to many and many to many between tables`using (var context = new SchoolDBEntities()){ var courses = context.GetCoursesByStudentId(1); foreach (Course cs in courses) Console.WriteLine(cs.CourseName);}`