SQL (SQLite engine)

Verify a delete removed the row

Easy30 pts~12 min
  • DELETE verification
  • Row counts
Practice app · Acme Commerce DB

A real SQL database (SQLite engine) seeded with an e-commerce and HR dataset, with schema browser and query runner.

Test URL
/lab/database-testing-verify-a-delete-removed-the-row

Your starter code already declares TEST_URL — never hardcode a host.

Objective

Delete a customer who never ordered and verify the row is gone while every other customer remains.

Your task

  1. 1Delete customer id 30 (Nora Johansson, who has no orders).
  2. 2Verify it is gone: SELECT COUNT(*) AS remaining FROM customers WHERE id = 30 must return 0.
  3. 3Also confirm the table now has 29 rows, i.e. exactly one row was removed.

Acceptance criteria

  • Only customer 30 was removed from customers
  • The last result set is the zero count for id 30

Constraints

  • Every run starts from a freshly seeded database, so your script must include its own setup statements.
  • Only the last result set of your script is compared, so finish with the verification query.

SQL (SQLite engine) · Database Testing · Data validation basics