Run the PIFD database backup
- Last UpdatedJun 04, 2025
- 1 minute read
- PI System
- PI Server 2024 R2
- PI Server
You can back up the PI AF SQL Server database and log files using any of the following approaches:
-
Schedule the Backup job to run at a specific time via the SQL Server Management Studio
-
Manually run the Backup job via the SQL Server Management Studio
-
Manually run the backup stored procedure independent of the Backup job
Code examples: T-SQL backup command
The following is an example of the T-SQL command that can be used to execute the stored procedure that creates a backup.
EXEC [dbo].[usp_backup] ;
To change the values for the outpath and alwaysfullbackup variables you could run the following T-SQL command:
EXEC [dbo].[usp_backup] @outpath = N'E:\Backup\', @alwaysfullbackup = 0 ;
where E:\Backup\ is the value assigned to the outpath variable and is the path used to save the backup and 0 is the value assigned to the alwaysfullbackup variable, meaning a differential backup will run.