Learn more about Toad for SQL Server
at Quest.com

Find solutions and downloads at the
Toad for SQL Server Support Portal

< To bookmark a page, right-click the Page Title and select Add to Favorites / Bookmark This Page

Toad for SQL Server 5.7

You are here: Use Version Control > Configure Version Control > Configure TFS or VSS

Configure TFS or VSS

You can configure version control to work with SQL scripts in the Editor, or you can configure it to work with database objects and SQL scripts in the Object Explorer. See Troubleshoot Version Control for more information.

Notes: 

To configure TFS or VSS to work with SQL scripts in the Editor

  1. Ensure that a supported version control client is installed on the computer where Toad is installed. See About Version Control for more information about tested version control clients and supported versions.
  2. Open an Editor window.
  3. Right-click anywhere in the toolbar area and select Version Control to display the Version Control toolbar.

    Tip: You can also access version control functionality from the File | Version Control menu when the Editor window has focus.

  4. Click to open the Version Control wizard.

  5. Review the following for additional information:

  6. Version Control System Page

    Description

    Type

    Select either Team Foundation Server or Visual SourceSafe.

    Note: If you select TFS, you must specify the workspace name for the provider in the Team Foundation Server Properties window that displays.

    Properties

    (TFS only) Click this button (beside the Type field) and specify the workspace name for the provider in the Team Foundation Server Properties window.

    Server

    Select one of the following:

    • For TFS, specify the server where your version control provider is installed and the port number (default is 8080) to use in the following format:

      http://MyServer:Port for TSF 2005, 2008

      http://MyServer:Port/TFS for TFS 2010

    • For VSS, select the folder where the Source Safe client is installed and the srcsafe.ini file (for example: C:\SourceSafe\VSS\srcsafe.ini).

    User name/ Password

    Enter login information for the version control provider and click Login.

    Note: For TFS only, if you leave the user name and password fields blank, Toad uses your default Windows credentials.

    Version Control Settings Page

    Description

    Version control folder

    Select the folder on the version control server where you want to check the scripts in.

    If you already have the Editor-managed scripts under version control, select the folder on the server where these scripts are located.

    Notes:

    • Version control automatically checks out the scripts in this folder and any subfolders to the location you specify in the Working folder field.
    • If you are managing SQL scripts from the Editor instead of the Object Explorer, make sure the version control folder used for Editor-managed scripts is different from the one used for objects and scripts managed in the Database Explorer.

    Working folder

    Select the root repository folder on the client computer to use as the default working folder for checking SQL scripts out.

    If you already have Editor-managed SQL scripts under version control, select the existing working folder for these.

  7. Add Scripts Using the Editor

Tips:

To configure TFS or VSS to work with objects and SQL scripts in the Object Explorer

  1. Ensure that a supported version control client is installed on the computer where Toad is installed. See About Version Control for more information about tested version control clients and supported versions.
  2. Right-click one or more objects in the Object Explorer and select Version Control | Version Control Wizard.

  3. Review the following for additional information:

    Configuration Type Page

    Description

    Configuration

    Select one of the following configuration types:

    • Server—Applies the same settings for all databases on a server.
    • Database—Applies custom settings for each database on a server. If selected, you must re-run the Version Control wizard for each database you want to place under version control.

      Tip: You can add databases to version control at a later time by selecting the database under Tools | Options | Version Control | Objects.

    Version Control System Page

    Description

    Type

    Select either Team Foundation Server or Visual SourceSafe.

    Note: If you select TFS, you must specify the workspace name for the provider in the Team Foundation Server Properties window that displays.

    Server

    Select one of the following:

    • For TFS, specify the server where your version control provider is installed and the port number (default is 8080) to use in the following format:

      http://MyServer:Port for TSF 2005, 2008

      http://MyServer:Port/TFS for TFS 2010

    • For VSS, select the folder where the Source Safe client is installed and the srcsafe.ini file (for example: C:\SourceSafe\VSS\srcsafe.ini).

    User name/ Password

    Enter login information for the version control provider and click Login.

    Note: For TFS only, if you leave the user name and password fields blank,Toad uses your default Windows credentials.

    Version Control Settings Page

    Description

    Version control folder

    Select the folder on the version control server where you want to check objects and scripts in.

    If you already have objects or scripts under version control, select the folder on the server where these objects or scripts are located.

    Notes:

    • Version control automatically checks out objects or scripts in this folder and any subfolders to the location you specify in the Working folder field.
    • If you are managing SQL scripts from the Editor instead of the Object Explorer, make sure the version control folder used for Editor-managed scripts is different from the one used for objects and scripts managed in the Database Explorer.

    Working folder

    Select the folder to use as the default working folder.

    If you already have objects under version control, select the working folder for these objects.

    Create/Change file name formats

    Specify the default format to use for objects. Objects are archived as script files in the version control provider.

    To change the default order, delete the default format and click + to select the order.

    Use default mode

    Clear this checkbox to override default folders for actions, such as create or alter scripts for each object (recommended for objects that are already under version control).

  4. Complete the wizard and add objects to version control. Depending on the number of objects selected, this process may take time.

    Note: If you rename a version controlled object, Toad drops the original object and its history from version control and prompts you to add the renamed object to version control This newly renamed object does not have any history associated with it.

    The following indicators display in the top-right corner of any object under version control:

    Object is under version control

    Object is checked out by another user

    Object is checked out by current user

    If version control is configured but an indicator does not display, open the Object Options page in Tools | Options | Version Control | Objects and select the checkbox for that object.

  5. Use the right-click menu to check files in/out, get the latest version, update the status, and other actions.
  6. If you configured version control for database objects, you can also version control SQL scripts using the Scripts tab (tab view or drop-down list mode) in the Object Explorer, as illustrated in the following example:

    The following folders or nodes are available: 

    Server Scripts folder/node

    Creates and manages SQL scripts that apply to all databases on a server.

    Note: This folder/node is only available if you configured version control at the server level.

    Scripts folder/node

    Creates and manages SQL scripts that apply to individual databases. If you are using the tree view, this displays below each database node, as illustrated in the following example: 

Tips:

 

Related Topics