Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow ability to set a backupset name #689

Closed
jhutchings87 opened this issue Oct 13, 2022 · 3 comments · Fixed by #864
Closed

Allow ability to set a backupset name #689

jhutchings87 opened this issue Oct 13, 2022 · 3 comments · Fixed by #864

Comments

@jhutchings87
Copy link

It would be nice to be able to set the backupset name to something specific or even a default of "Ola Hallengren Backup" within the DatabaseBackup procedure. This would allow tracking of Ola Backups vs VSS vs Veeam, etc. The option I am referring to is highlighted in bold below.

BACKUP DATABASE [Test] TO DISK = N'D:\SQL\Backup\TestBackup.bak' WITH COPY_ONLY, NOFORMAT, NOINIT, NAME = N'Custom Backup Job', SKIP, NOREWIND, NOUNLOAD, STATS = 10
GO

@Kevin-S-Lewis
Copy link

A VSS backup would be covered under the flag of is_snapshot. in msdb.dbo.backupset. Veeam takes VSS backups I believe, so you can easily filter between native and those.

https://learn.microsoft.com/en-us/sql/relational-databases/system-tables/backupset-transact-sql?view=sql-server-ver16

Software Vendor Id in the same table is less reliable... you're probably only see Microsoft's, as the other vendors often use Microsoft API calls.

If you want every backup to know its been done via calling Ola's backup maybe use the @description parameter, i.e.:

EXEC [dbo].[DatabaseBackup] @databases='USER_DATABASES', @Directory='S:\ThisBackupFolder',@description='Ola Backup',@BackupType='FULL'

Note: I am not knocking your request, and I do not represent Ola or know him on a personal level.

@olahallengren
Copy link
Owner

This feature has been added in Pull Request #864.

@olahallengren
Copy link
Owner

The pull request has now been merged to main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants