We read your photo as:
To create a new database, open your database management system (e.g., Microsoft Access). Select the option to create a new blank database, then specify the file name as StudDatabase and save it in y
ScanSolve AI Answer
Step-by-step solution
6 stepsCreate a database named
StudDatabase.To create a new database, open your database management system (e.g., Microsoft Access). Select the option to create a new blank database, then specify the file name as
StudDatabaseand save it in your designated candidate folder.Import the spreadsheet named
Practical.In your database management system, navigate to the 'External Data' tab or equivalent. Select 'New Data Source' and choose 'From File', then 'Excel'. Browse to your candidate folder, select the
StudentsInfoworkbook, and then choose thePracticalspreadsheet. Follow the wizard to import the data, ensuring that the first row contains column headers and that no extra fields are added.Create a query to extract male students from LAB 1 or LAB 2, grouped by subject.
To achieve this, you would use a SQL query.
Adjust the field widths in the query design view to accommodate the maximum data length for each field. Save the query as MaleLab1.
Give the two possible key fields of the table above.
The original
Practicaltable has two possible candidate keys that can uniquely identify each record:- (
StudNo,SubCode,Lab.No): This composite key uses all three fields to ensure uniqueness. - (
StudNo,Lab.No): This composite key also uniquely identifies each record in the table.
- (
Create the normalized tables
Students,Subjects, andLabWork.- Create
Studentstable: Copy thePracticaltable. Delete theSubCode,SubName, andLab.Nofields. Remove any duplicate records based onStudNo. Rename the table toStudents. The primary key will beStudNo. - Create
Subjectstable: Copy thePracticaltable. Delete theStudNo,Surname,Other Name,Sex, andLab.Nofields. Remove any duplicate records based onSubCode. Rename the table toSubjects. The primary key will beSubCode. - Create
LabWorktable: Copy thePracticaltable. Delete theSurname,Other Name,Sex, andSubNamefields. Remove any duplicate records based on the composite key(StudNo, SubCode, Lab.No). Rename the table toLabWork. The composite primary key will be(StudNo, SubCode, Lab.No).
- Create
Create a relationship in the database from the three created tables.
Establish relationships between the tables using primary and foreign keys:
- Create a one-to-many relationship between
StudentsandLabWorkby linkingStudents.StudNo(primary key) toLabWork.StudNo(foreign key). - Create a one-to-many relationship between
SubjectsandLabWorkby linkingSubjects.SubCode(primary key) toLabWork.SubCode(foreign key). Ensure referential integrity is enforced for these relationships.
- Create a one-to-many relationship between
Still stuck on this one?
Ask a follow-up, and the answer starts from this question.