So far the Kladde stores everything in a JSON file. For a console program that one person operates, that was right. On the web it is no longer enough: two requests can arrive at the same time, and one reads while the other writes. The contact list should come page by page, without the server loading every contact each time. And a rule like “the same email address exists only once” should hold even when two people save at the same moment.

That is exactly what database servers are for. In this module the Kladde moves to SQL Server. In this first lesson you start it as a container, create a first database, and make sure the password never ends up in the repository. In the next lessons you learn SQL, model the Kladde’s data, create indexes, and then connect the Kladde to the database with EF Core.

SQL Server, briefly

SQL Server is Microsoft’s relational database. Relational means the data lives in tables with fixed columns, and tables refer to each other through keys. You query and change data with SQL, which in SQL Server comes in a dialect called T-SQL (Transact-SQL). The same database engine also runs inside Azure SQL Database, which you meet in module 2.9. What you learn here applies there almost unchanged.

The course uses SQL Server 2025 (version 17.x) in the Developer edition. It has all the features, is free, and is licensed expressly for development and testing only, not for production. For the Kladde on your computer and in the codespace, that is exactly right.

SQL Server runs on Windows and Linux. But you don’t install it; you start it as a container: a ready-made Linux image that Microsoft provides as mcr.microsoft.com/mssql/server:2025-latest. A container can be created, thrown away, and created again in seconds, and everyone taking part has the same server. Module 2.9 goes deeper into what a container is; for now this is enough: a container is a self-contained process with its own file system that runs on a Docker service.

You should know two limitations before you start:

  • x86-64 only. The image is supported only on Intel and AMD processors. On a Mac with an Apple processor it runs at best in an emulation that Microsoft neither tests nor supports. If you have such a Mac, use the codespace. It runs on an x86-64 machine in the cloud.
  • Memory. SQL Server needs at least 2 GB of RAM. The smallest codespace with 2 cores and 8 GB is enough. With Docker Desktop, give the runtime at least 4 GB.