Tag: Backup Location

  • T-SQL Function to Get the Default Backup Folder

    Again, DBA’s are often faced with adhoc backup tasks that shall dump relevant data or log to the existing backup location for all other data/log dumps. Quick way to do so will invovling concatenating dynamic sql commands with the default backup folder location. [sourcecode language=”sql”] /* Script to create a function to get default backup…

  • T-SQL Stored Procedure to Get the UNC Path of Last Database Backup Location

    [sourcecode language=”text” wraplines=”false”] /* Script to get the last backup file location in the format of a UNC path for specified DB’s Last modified by Nick Xu on 2013-06-17 Usage: exec sp__GetLastDatabackupLocation ‘MDP’ */ use master go if exists (select * from sysobjects where name = ‘sp__GetLastDataBackupLocation’ and type = ‘P’) begin drop proc sp__GetLastDataBackupLocation…