powershelldba.de · Uwe Janke
REF: PSDB-SOB-2026 SCOPE: Ola Hallengren DatabaseBackup 2026-06-29 STATUS: v0.1.0.0
Module

75 backup parameters, clicked together and checked before the job ever runs.

sqmOlaBackupBuilder is a PowerShell module with a WinForms GUI for Ola Hallengren's dbo.DatabaseBackup. Every parameter of the current release has its own field and help text, the combination is validated live against the same rules the procedure enforces, and the result comes out as T-SQL, a sqlcmd line, PowerShell or a complete SQL Agent job with schedule. Connected to an instance, it runs a dry run with @Execute = 'N' so Ola itself confirms the call. No dbatools or other module dependency.

Why this exists

The error message arrives at 2 a.m., in the job history.

DatabaseBackup has 75 parameters. Many exclude each other, some only apply to LOG or DIFF, others only to LiteSpeed, SQL Backup, SQLsafe or Data Domain Boost. Get one wrong and the procedure refuses with "The value for the parameter ... is not supported", usually during the first scheduled run. sqmOlaBackupBuilder moves that moment to the second you click.

By handWith sqmOlaBackupBuilder
Parameter names copied from the documentation page, one typo per jobEvery parameter is a field with its type, default and help text
@CleanupTime with @URL, @Init = 'Y' on a log backup, found by the first failed runLive list of errors and hints, double-click jumps to the field
@NumberOfFiles = 4 with a file name that has no {FileNumber}Token menu for directory and file name patterns, checked on every change
Agent job built by hand in SSMS, schedule clicked separatelyComplete job script with category, owner, output file and daily, weekly or interval schedule
"Does the certificate exist? Is ZSTD available on this version?"Dry run with @Execute = 'N': Ola checks the server side rules and prints the BACKUP commands
Requirements

What it needs.

PowerShellWindows PowerShell 5.1 or PowerShell 7 on Windows (the GUI is WinForms), both verified
ModulesNone. The optional connection uses System.Data.SqlClient, so it runs on locked-down servers without PSGallery access. The PowerShell output format calls dbatools' Invoke-DbaQuery on the system where you run it
Ola HallengrenSQL Server Maintenance Solution on the target instance. Parameters match the release 2026-06-29; an older installation is detected and flagged
SQL ServerWhatever Ola supports; tested against SQL Server 2025 (CU7)
RightsBuilding the command needs no connection at all. Dry run and job creation run with your login, use one that may run Ola's backups and create Agent jobs (typically sysadmin; the job owner defaults to sa)
The GUI

Categories on the left, the finished command on the right.

Show-sqmOlaBackupGui uses the Visual Studio dark theme of the other powershelldba.de tools. Only parameters you actually set end up in the command; everything left at (Standard) keeps Ola's default.

  1. CategoriesBasics, target and retention, compression and performance, encryption, conditions, file names and directories, options, third-party software, execution. The badge shows how many parameters are set in each.
  2. Fields with helpDrop-downs for every Y/N and value list, pickers for databases and availability groups (keywords, include, exclude, wildcards), folder picker, token menu for @DirectoryStructure and @FileName.
  3. PresetsUser databases FULL / DIFF / LOG, system databases, ad-hoc COPY_ONLY, striping and tuning, dry run. A preset keeps the target directory you already entered.
  4. Command and findingsRegenerated on every change, with VS-style syntax highlighting. Copy, save as file, save and load the whole configuration as JSON (@EncryptionKey is never saved).
sqmOlaBackupBuilder in the dark Visual Studio theme. Left: category list with badges for set parameters, the Basics category with Databases USER_DATABASES minus one test database, BackupType FULL, Verify and Checksum set to Y, and the help text for Databases below. Right: output format SQL Agent job with a daily schedule at 01:00, the generated job script with syntax highlighting, and the validation status valid.
The user databases FULL preset with a network target and two backup files, written as a SQL Agent job with a daily schedule.
Validation

The procedure's own rules, checked while you click.

More than 100 checks are taken from the parameter block of DatabaseBackup itself. Errors mean Ola would refuse the call; hints flag things that are allowed but rarely intended, such as no @CleanupTime or @LogToTable = 'N'.

AreaExamples
SelectionExactly one of @Databases and @AvailabilityGroups; @BackupType mandatory
Target@URL excludes @Directory, @MirrorDirectory and third-party software; no @CleanupTime with URL; same number of mirror directories
Value ranges@NumberOfFiles 1 to 64 and divisible by the number of targets, @MaxTransferSize in 64 KB steps up to 20 MB, @BlockSize list, @Stats 1 to 100
Backup type@NoRecovery and @MinLogSizeSinceLastLogBackup only for LOG; @Init, @Format, @ReadWriteFileGroups never for LOG; @MinModificationLevel only DIFF with @ChangeBackupType = 'Y'
EncryptionAlgorithm per backup software, native needs a certificate or an asymmetric key, @EncryptionKey only for third-party software
Third-party@Threads, @Throttle, @AdaptiveCompression, @ExpireDate, @RetainDays, Data Domain Boost mandatory fields
File namesMust end with .{FileExtension}, no path separators, {FileNumber} with several files, unknown tokens, {DatabaseName} and {BackupType} in the directory structure when cleaning up
Output

Four formats, one source of truth.

EXECUTE [master].[dbo].[DatabaseBackup]
    @Databases     = 'USER_DATABASES, -Test%',
    @Directory     = '\\backupsrv\sql',
    @BackupType    = 'FULL',
    @Verify        = 'Y',
    @CleanupTime   = 168,
    @Compress      = 'Y',
    @Checksum      = 'Y',
    @NumberOfFiles = 2,
    @LogToTable    = 'Y';
FormatUse
T-SQLAligned EXECUTE, parameters in the order of the procedure
sqlcmd (CmdExec)One line in the style of Ola's own job steps, with the Agent token $(ESCAPE_SQUOTE(SRVR)) when not connected
PowerShellInvoke-DbaQuery ... -QueryTimeout 0 -MessagesToOutput -EnableException
SQL Agent jobComplete script: category, owner, T-SQL step, optional output file in SQLLOGDIR, daily, weekly or interval schedule. Stops with a message if a job of that name exists
Dry run and job creation

Let Ola confirm the call before it is scheduled.

Some rules depend on the server: edition, version (ZSTD needs SQL Server 2025, QAT Standard or Enterprise), existing directories, certificates, credentials, installed backup software. The dry run sends the command with @Execute = 'N'; Ola then checks everything and only prints the BACKUP, VERIFY and cleanup commands it would run. Nothing is backed up.

  1. ConnectWindows or SQL authentication. The status line shows SQL version, edition and the installed Ola version; databases, availability groups, certificates, asymmetric keys and credentials become drop-downs.
  2. Dry runServer messages appear under Dry run / server output, errors in red.
  3. Create jobIn the SQL Agent job format, after a confirmation. Refused while the validation list shows errors.
Scripting without the GUI

The same generator for deployment scripts.

FunctionPurpose
Show-sqmOlaBackupGuiThe WinForms GUI, optionally connected right away with -SqlInstance / -SqlCredential
New-sqmOlaBackupCommandBuilds T-SQL, sqlcmd, PowerShell or an Agent job script from a hashtable, no connection needed
Test-sqmOlaBackupParameterOffline rule check, returns errors and warnings per parameter
Quick start

Install, then the GUI, or one call.

# Installation - AllUsers when elevated, otherwise CurrentUser
Install.cmd

# GUI (or double-click Start-sqmOlaBackupBuilder.cmd without installing)
Show-sqmOlaBackupGui -SqlInstance SQL01

# Log backup every 15 minutes as an Agent job
$p = @{ Databases = 'USER_DATABASES'; BackupType = 'LOG'; ChangeBackupType = 'Y'; CleanupTime = 168; LogToTable = 'Y' }
Test-sqmOlaBackupParameter -Parameter $p
New-sqmOlaBackupCommand -Parameter $p -Format AgentJob -ScheduleType Interval -IntervalMinutes 15 -JobOutputFile

The last servers and the login name are remembered in %APPDATA%\sqmOlaBackupBuilder\config.json; the password never is. Tests\Test-sqmOlaBackupBuilder.ps1 -MaintenanceSolution MaintenanceSolution.sql compares the parameter list with a new Ola release, so new parameters show up immediately.

Next steps

Build your first backup job in a minute.

No dependencies to install: unzip, double-click Start-sqmOlaBackupBuilder.cmd, pick a preset.