Track contentsDay 0 of 30

Day 0: One-time setup

Beginner1 hr 15 minWorks in: SQL Server 2025, SSMS 22, Windows 10 or 11
On this page
  1. 1. What you are installing, and why
  2. 2. Install SQL Server 2025 Standard Developer
  3. 3. Install SSMS 22
  4. 4. Connect to your server
  5. 5. Get the course scripts
  6. 6. Build the training database
  7. 7. Confirm everything works
  8. 8. Troubleshooting setup and connection problems
  9. 9. Completion checklist
  10. References

By the end of this lesson you can

  • Install SQL Server 2025 Standard Developer and SSMS 22
  • Connect to your local server and build the RetailLab training database
  • Confirm that all 25 validation checks pass
Level Beginner
Estimated time About 1 h 15 min (most of it waiting for installers)
Prerequisites A Windows 10 or 11 (x64) computer on which you can install software as an administrator; about 10 GB free disk space; an internet connection
Outcome SQL Server 2025 Standard Developer and SSMS 22 installed, the RetailLab training database built, and all 25 validation checks passing

Work or corporate laptop? Installing a database server needs local administrator rights, and many organisations block it through device policy. If the installer will not start or is blocked, ask your IT team for an approved installation or use a personal computer. Do not try to work around your organisation’s controls.


1. What you are installing, and why

Component What it is Analogy
SQL Server 2025 Standard Developer The database engine: a Windows service that stores data and runs your T-SQL. Free for development and testing; not licensed for production use. The kitchen
SSMS 22 (SQL Server Management Studio) A Windows application where you write queries, run them and see results. The order pad and serving hatch
RetailLab The training database you will build inside SQL Server from the course scripts. Today’s ingredients

SSMS and SQL Server are separate installs. SSMS can connect to many servers; here it connects to the one on your own computer, called localhost.


2. Install SQL Server 2025 Standard Developer

  1. Go to Microsoft’s SQL Server downloads page: https://www.microsoft.com/en-us/sql-server/sql-server-downloads.
  2. Under the free developer editions, download the SQL Server 2025 developer installer. At the time of writing it downloads a small launcher named SQL2025-SSEI-EntDev.exe. The launcher fetches the rest during installation.
  3. Run the launcher. When asked for an installation type, choose Custom (not Basic), because Custom lets you pick the edition. Accept the default media location and select Install. The launcher downloads the setup files (a few minutes) and opens the SQL Server Installation Center.
  4. In the Installation Center, select Installation → New SQL Server standalone installation or add features to an existing installation.
  5. Work through the wizard pages:
Wizard page What to choose
Edition Select Specify a free edition and choose Standard Developer. If only Enterprise Developer is offered, choose it — every lesson runs unchanged on it.
License Terms Accept.
Microsoft Update Your choice. Turning it on keeps the engine patched.
Install Rules A Windows Firewall warning is normal and can be ignored for a local-only install. Any Failed rule must be fixed before continuing (see section 8).
Azure Extension for SQL Server Clear the checkbox. It connects the server to Azure management services and is not needed for this course.
Feature Selection Tick Database Engine Services only. Nothing else is needed.
Instance Configuration Choose Default instance (instance ID MSSQLSERVER). This lets you connect with the server name localhost.
Server Configuration Leave the default service accounts.
Database Engine Configuration → Server Configuration tab Keep Windows authentication mode. Under Specify SQL Server administrators, select Add Current User. Your Windows account then has full control of this instance.
Ready to Install Select Install. Expect 5–15 minutes.
  1. When the Complete page shows Succeeded for Database Engine Services, close the wizard and the Installation Center.

Check: press Windows + R, type services.msc, press Enter and find SQL Server (MSSQLSERVER). Its status should be Running.


3. Install SSMS 22

  1. Download the SSMS 22 installer from Microsoft: https://aka.ms/ssms/22/release/vs_SSMS.exe. (Overview page: https://learn.microsoft.com/en-us/ssms/install/install.)
  2. Run vs_SSMS.exe and choose Yes if User Account Control asks. It first installs the Visual Studio Installer, which then installs SSMS.
  3. Accept the terms, leave the default selection (the core SSMS components are all this course needs) and select Install.
  4. When it finishes, start SQL Server Management Studio 22 from the Start menu. Signing in to sync settings is optional; you can skip it.

4. Connect to your server

When SSMS starts, the Connect to Server dialog opens. (If it does not, select File → Connect Object Explorer.)

Field Value Why
Server type Database Engine
Server name localhost The default instance on this computer. . and (local) also work.
Authentication Windows Authentication Uses the account you added as an administrator during setup
Encryption Mandatory (default) SSMS encrypts connections by default
Trust server certificate Ticked A fresh local installation uses a self-signed certificate that Windows does not trust. Ticking this box skips certificate validation. That is acceptable for a private local training server; on shared or production servers, use a trusted certificate instead.

Select Connect. Object Explorer (left pane) now shows your server with folders such as Databases and Security.


5. Get the course scripts

  1. Create the folder C:\RetailLab\scripts\setup.
  2. Download the six files — all at once as a zip file, or one at a time from the table below — and copy them into it:
File Purpose Destructive?
00_create_database.sql Creates the empty RetailLab database (drops it first if it already exists) Yes — removes RetailLab only
01_create_tables.sql Creates the schemas, tables and constraints No
02_load_core_data.sql Loads the core Ridgeway Outdoor data in one transaction No
03_validate_core_data.sql Runs 25 read-only checks No
04_reset_training_data.sql Runs 00 → 03 in one go (needs SQLCMD Mode) Yes — removes RetailLab only
05_generate_performance_data.sql Builds the large Perf dataset for Week 4. Don’t run it now — Day 22 tells you when Yes — drops and recreates the Perf tables only

You can use another folder; if you do, update the path inside 04_reset_training_data.sql before you use it.


6. Build the training database

Run the first four scripts in order. For each one:

  1. In SSMS, select File → Open → File… (Ctrl + O) and open the script.
  2. Look at the Available Databases drop-down on the SSMS toolbar. You do not need to change it: every script starts with a USE statement that switches to the right database.
  3. Select Execute on the toolbar, or press F5.
  4. Read the Messages tab at the bottom. Confirm there are no red error messages before moving on.
Order Script What you should see
1 00_create_database.sql A results grid with one row: RetailLab, 170, Latin1_General_100_CI_AS, SIMPLE
2 01_create_tables.sql Message: Schemas and tables created.
3 02_load_core_data.sql Message: Core data loaded. Now run 03_validate_core_data.sql.
4 03_validate_core_data.sql A 25-row grid where every Status is PASS, then a summary row: ALL 25 CHECKS PASSED - RetailLab is ready.

In Object Explorer, right-click Databases and select Refresh. Expand RetailLab → Tables: you should see 13 tables, such as HR.Employee, Sales.SalesOrder and Staging.CustomerImport.

How the reset script works

04_reset_training_data.sql uses SQLCMD Mode, a feature of SSMS that understands extra commands beginning with a colon, such as :r (run another file). To use it:

  1. Open the script and select Query → SQLCMD Mode. SQLCMD lines are highlighted in grey.
  2. Check that the :setvar ScriptFolder line points to your scripts folder.
  3. Press F5.

You will use this whenever a lesson asks you to start from a clean state. If you prefer, simply run scripts 00 to 03 one after another instead.


7. Confirm everything works

Open a new query window (New Query on the toolbar, or Ctrl + N), paste the following and press F5:

USE RetailLab;
GO

SELECT  @@SERVERNAME                    AS ServerName,
        SERVERPROPERTY('Edition')       AS Edition,
        SERVERPROPERTY('ProductVersion') AS ProductVersion,
        DB_NAME()                       AS CurrentDatabase,
        (SELECT COUNT(*) FROM Sales.SalesOrder) AS OrderCount;

Expected result: one row where Edition contains Developer, ProductVersion starts with 17., CurrentDatabase is RetailLab and OrderCount is 376. Your server name is your computer’s name.

If you see all of that, setup is complete.


8. Troubleshooting setup and connection problems

Symptom Likely cause Fix
The launcher or setup will not start, or says it is blocked by policy No administrator rights, or device policy on a managed computer Ask your IT team, or use a personal computer
An Install Rules item shows Failed Usually a pending Windows restart or missing Windows updates Restart Windows, install pending updates and run setup again
Setup rejects the selected edition on Windows 10/11 The edition is not supported on a client operating system Go back to the Edition page and choose Standard Developer
A network-related or instance-specific error occurred… when connecting The service is not running, or you installed a named instance Check services.msc: start SQL Server (MSSQLSERVER). If you installed a named instance such as SQL2025, connect to localhost\SQL2025
The certificate chain was issued by an authority that is not trusted Self-signed certificate on the local instance Tick Trust server certificate in the connection dialog (section 4)
Login failed for user ‘COMPUTER\you’ Your Windows account was not added as a SQL Server administrator Sign in to Windows with the account that installed SQL Server, or re-run setup, choose Add features to an existing instance, and add your account
00_create_database.sql fails with permission denied in database ‘master’ Your login cannot create databases Same fix as above: your account needs to be a SQL Server administrator on this training instance
01_create_tables.sql fails with There is already an object named … Script 01 has already been run Run 00, 01 and 02 again in order
02_load_core_data.sql fails with Violation of PRIMARY KEY constraint Data has already been loaded Run 00, 01 and 02 again in order. Because script 02 runs in one transaction, a failed run leaves no partial data
Incorrect syntax near ‘:’ when running the reset script SQLCMD Mode is off Select Query → SQLCMD Mode and run it again
A fatal scripting error occurred… Could not find file in the reset script The ScriptFolder path is wrong Correct the path on the :setvar line; keep the quotes
New tables do not appear in Object Explorer Object Explorer does not refresh automatically Right-click the Tables folder and select Refresh
Red squiggly lines under valid table names SSMS’s IntelliSense cache is out of date Select Edit → IntelliSense → Refresh Local Cache (Ctrl + Shift + R)
Validation shows a FAIL A script was skipped or a later change altered the data Run the reset script, then 03_validate_core_data.sql again

9. Completion checklist

  • SQL Server (MSSQLSERVER) shows as Running in services.msc.
  • SSMS 22 connects to localhost with Windows Authentication.
  • 03_validate_core_data.sql reports ALL 25 CHECKS PASSED.
  • The confirmation query in section 7 returns OrderCount = 376.
  • You know how to run 04_reset_training_data.sql in SQLCMD Mode.

References