levo

Databases, Normalisation and Entity Modelling

Second normal form

  • 3 things to know
  • Component 2
Start revising · £5/month

Overview

Rule for second normal form, partial dependency and partial dependencies in ENROLMENT(StudentID, StudentName, TutorGroup, CourseCode, CourseTitle, TeacherID, TeacherName).

What you need to know

Answer each one before you reveal it.

Your recallNot started
Key term

State the rule for second normal form.

Key term

What is a partial dependency?

Key term

Why can a table with a single-attribute primary key never break second normal form?

Questions from this subtopic

Each one with the model answer underneath.

  1. 1

    State the rule for second normal form.

    Model answer

    A table is in second normal form when it is in first normal form and has no partial dependencies. Every non-key attribute must depend on the whole primary key.

  2. 2

    What is a partial dependency?

    Model answer

    A partial dependency exists when a non-key attribute depends on only part of a composite primary key. StudentName depending on StudentID alone is a partial dependency.

  3. 3

    Why can a table with a single-attribute primary key never break second normal form?

    Model answer

    A single-attribute key has no parts, so no attribute can depend on only part of it. A first normal form table with a simple key is automatically in second normal form.

  4. 4

    Identify the partial dependencies in ENROLMENT(StudentID, StudentName, TutorGroup, CourseCode, CourseTitle, TeacherID, TeacherName).

    Model answer

    StudentName and TutorGroup depend on StudentID alone. CourseTitle, TeacherID and TeacherName depend on CourseCode alone.

  5. 5

    Convert that table to second normal form.

    Model answer

    STUDENT(StudentID, StudentName, TutorGroup) and COURSE(CourseCode, CourseTitle, TeacherID, TeacherName) are separated out. ENROLMENT(StudentID, CourseCode, Grade) keeps the composite key and any attribute depending on both.

  6. 6

    Which attribute in the enrolment example genuinely depends on the whole composite key?

    Model answer

    The grade a student achieved depends on both the student and the course. Grade therefore stays in the ENROLMENT table.

Other ways to work this

The same content, four other ways.

Everything in your subscription

Runs, plus a mode for every other kind of session.

1Flash
2Imposter
3Fade
4Brain dump

Learn every subtopic in runs of four questions

Facts flash and fade, a wrong word hides in some of them, and a brain dump decides which questions are locked in.

Data Structures: Arrays, Records and Hash Tables
Stacks, Queues, Linked Lists and Trees
Boolean Logic and Simplification
Algorithms, Pseudo-Code and Programming Constructs

Cram the night before, weakest topic first

A quick scan finds your weakest topics. Recall each fact you missed three times in a row.

KDW to HAT.
decryptsencryptscompresses

Blank Blitz consolidates the facts

Rapid timed gap-fills on the terms and numbers you need to recall without thinking.

✓What it iscovered
~Why it happenspartly there
How long it lastsnot there yet

Explain It tests your understanding

Explain a concept in your own words and see which of its points you covered.

Backup means the copy of the data.
TrueFalse

Test It catches misconceptions

Spot the fault in a statement. The faults are the mistakes students make most often.

721941163128510

Brain Breaks between sessions

Short focus games to reset attention, so the next set lands better than the last.

Every question in Databases, Normalisation and Entity Modelling, on a schedule.

Learn it in runs of four questions, each ending on a brain dump against the clock. Every question you lock in comes back the next day, then at longer gaps, each time just before you would forget it.

Or £46 a year, about £3.83 a month. Cancel anytime.