Friday, March 30, 2012

Instance name contains a dash

Hello

We are in the process of upgrading our SQL 2K server to a cluster environment. Currently the server is setup as a default instance running on a single box with log shipping as a warm backup

It is required to create an instance name for the new cluster to work. My question is

1) Has anybody tried to have an instance name that dash (-) in it.

Example: \\SERVERNAME\xxx-xx-xxx

I am told that it is not possible to have a server instance named this way. Would like to know if this naming convention is possible under SQL2K If not what is the suggested workaround

This will save a lot of time in application modifications

Thanks in advance

Gabe J

Don't do it, invest the work now and you will have a much more relaxing future. If it takes much time to modify your application to work with another instance name you probably have a design issue in your application.

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks for the advice.

SQL 2000 books online does not specifically mention that dash (-) cannot be used in an instance name ( you can even create tables and other objects in a database that contains a dash in them why not instance name?). Could you please be a little more specific as what exactly the issues would be if the instance name contained dashes.

I have to justify the requirement to make program changes, for that I need to understand what the issues are going to be.

Appreciate your help

Gabe J

|||

I don′t have any specific issue in mind that I can tell of if you use special characters in instance names. Sure you can have special characters in Tables and other objects, but "What you can do" is often the opposite "What is prefered to do". As from my experience I wouldn′t bet on that horse and take the risk of naming the object or even the instance with special characters, although I can. Thats just my two cents, perhaps someone has another opinion about that, but unless you have a hand on your code and have the opportunity to correct that thing (as of my opinion) I would that effort in it.

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

In general I agree with what Jens has to say. As far as I know, putting a dash in the instance name is supported. I remember back in the 7.0 days testers went to a lot of trouble to make sure that dashes worked fine in the server name. I don't remember finding any issues there (but it was a long time ago). I do seem to remember that our automation at the time needed multiple changes to run on those servers. :(

The effort was worth it for Microsoft but might not be for your arbitrary application.

|||

One of the suggestions made to get around with this issue is to place a registry hack by adding a key called "Connectto" in the following node

HKEY_LOCAL_MACHINE\SOFTWARE\MICROSOFT\MSSQLServer\Client\

And specify the value as the OLD server name = "XXX-XX-XXX"

and data = DBNMPNTW,\\<New Server name>\pipe\MSSQL$<Instance name>\sql\query

When applications connect irrespective of the connection string, this registry value connects to the SQL server instance.

Seems to work . Agree this is just a workaround instead of solving the real issue of making application modifications.

Has anyone tried this ?

Thanks for you suggestions

|||

Not sure where you heard about this registry hack, but I would not recommend using it unless it was mentioned in a specific Microsoft article...This ***hack*** may not work after a future release. Looks like this workaround maybe setting up a alias for the server. If this is the case, you should use SQL Server Configuration Manager instead.

As others have said, I am not really sure if dashes are supported, but I would not use...SQL Server maybe able to handle it fine, but some other external component may not.

Thanks,

Peter Saddow

|||

Agree that this is a **hack**. The SQL Server is a 2K version not 2005. How do I use the configuration manager to set up and alias name for the instance at the server level?

Thanks

|||

For SQL Server 2000, use SQL Server Client Network Utility. Select the "Alias" tab and enter the required information.

Hope this helps,

Peter Saddow

No comments:

Post a Comment