replace all references to a drive inside the jobs to another drive

by marcello miorelli   Last Updated August 10, 2018 11:06 AM

I have a server where all my sql server backups are currently being saved to the G: drive.

Now there is no enough disk space on drive G: to keep backups for the last 5 days. I have asked to add another 100 GB to this G: drive but that was not possible, so they gave me another drive instead, the I: drive with extra disk space, as you can see on the picture below.

enter image description here

Now I need to replace all the references to the G: drive in the sql server jobs below to point to the new I: drive.

enter image description here

Suppose I have 3 servers in the same situation, how can I achieve this by T-SQL?



Related Questions


SQL Server 2016 Temporal tables metadata

Updated March 27, 2018 14:06 PM


How to get the definition of a database trigger?

Updated August 09, 2018 15:06 PM