How to add SQL Server 2000 Stored Procedures to Visual SourceSafe by using Visual Studio .NET (818368)
The information in this article applies to:
- Microsoft Visual SourceSafe 6.0c
- Microsoft Visual Studio .NET (2003), Enterprise Architect Edition
- Microsoft Visual Studio .NET (2003), Enterprise Developer Edition
- Microsoft Visual Studio .NET (2003), Academic Edition
- Microsoft SQL Server 2000 (all editions)
- Microsoft SQL Server 2000 64 bit (all editions)
SUMMARYThis step-by-step article discusses how to add Microsoft
SQL Server 2000 Stored Procedures to Visual SourceSafe (VSS) by using the
Source Control feature in Microsoft Visual Studio .NET. There are two types of
configuration for adding Stored Procedures by using Source Control:
- The VSS database is installed on the same computer as SQL
Server.
- The VSS database is installed on a remote
computer.
back to the topInstall Visual
SourceSafe on the computer running SQL ServerTo install VSS on the computer running SQL Server, follow these
steps:
- Run the Setup.exe file that is located on the VSS
installation CD-ROM.
- Change the Log On account of the
MSSQLServer service to run under a user account that has Read and
Write user rights for the VSS database folder.
- In the VSS Administration tool, add the user name and
password from step 2 for the VSS database. SQL Server uses this account to
carry out checkout and check-in operations in VSS.
back to the topInstall Visual SourceSafe client componentsIf the VSS database is installed on a remote computer other than
the computer running SQL Server, you must install VSS client components on the
computer running SQL Server. To do this, follow these steps:
- Run Netsetup.exe from the folder of the remote computer
where the VSS database is installed.
- Change the Log On account of the
MSSQLServer service to run under a user account that has Read and
Write user rights for the VSS database folder that is located on the remote
computer.
- In the VSS Administration tool, add the user name and
password from step 2 to the VSS database that is located on the remote
computer. SQL Server uses this account to log on to the remote computer to
carry out checkout and check-in operations in VSS.
back to the topRun
the MSSQLServer service under a domain account- On the computer running SQL Server, open SQL Server
Enterprise Manager.
- Under SQL Server Group, right-click
(LOCAL), and then click
Properties.
- Click the Security tab. Under
Startup service account, click This
account.
- Type the User ID and
Password.
- Click OK.
back to the topInstall Visual Studio .NET Version Control server components on the computer running SQL Server- Run Visual Studio .NET Setup.
- Under Server Components, select VS 6 Stored Procedure Version Control.
- Click Update now or Install to install the required components.
back to the topAdd a user to
Visual
SourceSafe Administrator on the computer running SQL Server- Start the Visual SourceSafe 6.0 Administrator
tool.
- On the Users menu, click Add
User.
- In
the Add User dialog box, type the User Name
and Password.
- Click OK.
back to the topEnable version control
for Stored Procedures on the computer running SQL ServerBy default, version control is not
enabled for Stored Procedures. To enable the version control for Stored
Procedures, follow these steps:
- Start Visual Studio .NET.
- On the Tools menu, click
Options.
- In the left pane, expand Database Tools,
and then click Server Explorer.
- Under Stored Procedure, click to select
the check box for Enable version control.
- Click OK.
back to the topAdd Stored Procedures to Visual
SourceSafeTo add the Stored Procedures to Visual SourceSafe, follow these
steps:
- On the computer running SQL Server, verify that SQL Server
is running under a domain account.
- Use the VSS Administration tool, to verify that the domain
account has been added to the VSS database.
- Run Setup for Visual Studio .NET. On the Options Page,
expand Server Components, and then click to select the check
box for VS 6 Stored Procedure Version Control. Verify that
only VS 6 Stored Procedure Version Control is
selected.
- Start Visual Studio .NET, and then enable Version Control
for Stored Procedure (see the "Enable Version
Control for Stored Procedures" section).
- In Server Explorer, expand Data
Connections, and then expand the relevant Database
Reference.
- Right-click the Stored Procedures folder,
and then click Add to Source Control.
- In the Enable Source Control dialog box,
type the Source Control Database Location.
Note The Source Control Database Location is the path
of the VSS database.
- If the VSS database is located on the computer running
SQL Server, type the local path relative to the computer running SQL Server (for example, C:\VSS\srcsafe.ini).
- If the VSS database is located on a remote computer,
type the location of the remote computer as a universal naming convention (UNC)
path (for example,
\\ProjectServer\VSS\srcsafe.ini).
- In the Source Control Project Name text
box, type the VSS project name.
Note Do not use the "$/" prefix in the Source Control Project
Name text box. Visual Studio ,NET adds this prefix
automatically. - In the Source Control Login dialog box,
type the VSS Login ID and the Password, and then
click OK.
- In Server Explorer, expand the Stored
Procedures folder, right-click the Stored Procedure name, and then
click Add to Source Control.
Note In Server Explorer, a lock icon appears next to the name of each
Stored Procedure that has been successfully added to Source
Control.
In Server Explorer, you can right-click the Stored Procedure
name to perform typical VSS actions such as Check Out,
Check In, and Undo Checkout. - You can add more than one Stored Procedure at the same time
to VSS. To select more than one Stored Procedure, follow these steps:
- Hold down CTRL, and then click each Stored Procedure
that you want to add.
- When you have selected the Stored Procedures,
right-click any selected Stored Procedure, and then click Add to Source
Control.
back to the
topREFERENCESFor more information about Visual Studio .NET Server
Explorer, and about how to enable Source Control, visit the following Microsoft
Web sites: back to the
top
Modification Type: | Major | Last Reviewed: | 9/28/2005 |
---|
Keywords: | kbHOWTOmaster kbStoredProc kbSrcControl kbhowto KB818368 kbAudDeveloper |
---|
|
|
©2004 Microsoft Corporation. All rights reserved.
|
|