A3.3 Database programmingA3.3.3

Using SQL to update data in a database

Explain how SQL can be used to update data in a database

SL + HL≈ 55 minCommand term: ExplainPremium

In this lesson

  • Adding rows with INSERT INTO, changing them with UPDATE … SET and removing them with DELETE
  • Why WHERE matters so much in UPDATE and DELETE
  • How indexes speed up queries but make every change to indexed data more work
  • Why indexes are rebuilt or reorganised after large changes

This lesson is part of Premium

Every topic has one free lesson. Premium unlocks every interactive lesson, the exam-style questions at the end of each one, and the rest of Praxis IB.

What's inside

  1. LearnChanging data with SQL
  2. LabKeep the shop up to date
  3. LearnIndexes: faster reads, more work on writes
  4. LabWatch the index change
  5. CheckQuick check
  6. ExamWorked exam answer
  7. ReviewMistakes examiners see
  8. Exam practiceExam-style questions

Ends with 5 exam-style questions worth 13 marks, with a self-marking markscheme.