Thursday, April 02, 2026

Chess with SQL

 Chess in Pure SQL - DB Pro Blog

-- Kasparov vs Topalov, 1999
-- After the legendary 24. Rxd4!! rook sacrifice
INSERT INTO board (rank, file, piece) VALUES
(1, 6, '♖'), (1, 7, '♔'),
(2, 1, '♙'), (2, 6, '♙'), (2, 7, '♙'), (2, 8, '♙'),
(3, 2, '♙'), (3, 3, '♗'),
(4, 4, '♖'),  -- The sacrificed rook
(5, 3, '♙'),
(8, 2, '♜'), (8, 7, '♚'),
(7, 1, '♟'), (7, 6, '♟'), (7, 8, '♟'),
(6, 



Sample DB: chinook-database, netflix-db, and other datasets

 lerocha/chinook-database: Sample database for SQL Server, Oracle, MySQL, PostgreSQL, SQLite, DB2 @GitHub

Chinook database is an alternative to the Northwind database, being ideal for demos and testing ORM tools targeting single and multiple database servers.

  • DB2
  • MySQL
  • Oracle
  • PostgreSQL
  • SQL Server
  • SQLite


Sample database based on the data from the Netflix Engagement Report and the Netflix Global Top 10 weekly list, it includes movies and TV shows for learning and practice purposes.

Supported Database Servers

  • MySQL
  • Oracle
  • PostgreSQL
  • SQLite
  • SQL Server

The Sakila database is a nicely normalised database modelling a DVD rental store (






other sample datasets




movies.json contains a list of 1900-2023 movies from Wikipedia in convenient form: an array of objects, each representing a movie, with a titleyearextractthumbnailcast (array), and genres (array):