On Windows 8, I want to schedule a SQL Server backup using two files:
powershell.ps1
sqlcmd -S GT044 -E -i backup.sql
and filename.sql
BACKUP DATABASE [DB_NAME] TO DISK ='D:\backup.bak'
When I manually run powershell.ps1
in PowerShell, it works and backs up the database. But when I schedule the powershell.ps1
, it does not backup the database.