Wednesday, November 09, 2005

 

What is in a name?

We often use a dot “.” or a string “(local)” to connect the default instance in the local (stand alone) SQL Server. However this shortcut doesn’t work with cluster virtual (SQL) server. We need to give the actual virtual (SQL)server name. When we use these shortcuts, SQL Server resolved this as a local system. That is, it resolves the shortcut as a host name of the server. In the standalone default SQL instance, the Windows command HOSTNAME and T-SQL command SELECT @@servername gives the same result.

In clustered SQL Server environment, the shortcuts points to the node name which owns the virtual SQL Server not to the virtual instance name. Consequently, the shortcuts do not connect. Here, the Windows command HOSTNAME and T-SQL commands SELECT @@servername doesn’t give the same result. Still, if we want to use the shortcuts then we need to create server alias with shortcut literals as the alias name using “Client Network Utility”.

In DTS, selecting (local) in the server list rather than the name of the SQL server will enable the package to connect to the local server regardless of where the package is executed. If, however, we can specify a particular server name in the package and execute the package on a remote server, the package will attempt to connect to the original server rather than the local server. Understanding the effect of the server name in a package will enable us to ensure the package executes the way it was intended.

Comments: Post a Comment

<< Home

This page is powered by Blogger. Isn't yours?