levo

Normalisation and Structured Query Language

The principles of SQL

  • 3 things to know
  • A2 Unit 1
Start revising · £5/month

Overview

Structured Query Language, two main divisions of SQL and SQL being a standard.

What you need to know

Answer each one before you reveal it.

Your recallNot started
Evaluation

Why is it an advantage that an SQL query states what is wanted rather than the method of retrieving it?

Key term

What is a null in SQL, and how does it differ from zero?

Key term

What are privileges in SQL?

Questions from this subtopic

Each one with the model answer underneath.

  1. 1

    What is Structured Query Language?

    Model answer

    Structured Query Language is the standard language for defining and manipulating data in a relational database. It is declarative: a statement says what is wanted, and the database management system decides how to obtain it.

  2. 2

    What does it mean to say SQL is declarative rather than procedural?

    Model answer

    A declarative statement describes the result required without stating the steps, so the database chooses the method. A procedural language would require the programmer to say how to find and combine the rows.

  3. 3

    Why is it an advantage that SQL does not state the method?

    Model answer

    The database can choose a different method as the data grows or as indexes change, so the same statement keeps working efficiently without being rewritten, and the programmer need not know how the data is stored.

  4. 4

    What are the two main divisions of SQL?

    Model answer

    Data definition language creates and alters structure, with statements such as CREATE, ALTER and DROP. Data manipulation language works on the contents, with SELECT, INSERT, UPDATE and DELETE.

  5. 5

    What is meant by SQL being a standard?

    Model answer

    SQL is defined by an international standard, so the core of the language is the same across products and a query written for one relational database will usually run on another, although every product adds extensions of its own.

  6. 6

    Why does SQL work on sets rather than one row at a time?

    Model answer

    A single SQL statement acts on every row that meets its condition, so one UPDATE can change a thousand rows. That is why an UPDATE without a WHERE clause changes the whole 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.

Software and the Development Environment
Defining Data: Types, Variables and Classes
Program Control Structures
Objects, Classes and Data Structures

Cram the night before, weakest topic first

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

A null is the of one.
absencepresencetype

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.

An error is the mistake a person made.
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 Normalisation and Structured Query Language, 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.