How to test an installation of SQL Server 2000 (Command Prompt)
From How to Install SQL Server 2000
How To
How to test an installation of SQL Server 2000 (Command Prompt)
To test the installation
- Start Microsoft® SQL Server™ 2000 by entering from a command prompt:
For the default instance, use:
net start mssqlserverFor a named instance, include the instance name, for example:
net start MSSQL$Instance1 - Connect to SQL Server by entering:
For the default instance, use:
osql /Usa /P <administrator password>For a named instance, include both the server and instance name, for example:
osql /Usa /P /S Machine1\Instance1When osql connects, this osql prompt appears:
1>If osql cannot connect, an ODBC error is returned.
- Enter a simple query, such as:
SELECT @@SERVERNAME GOThe osql utility returns the server name:
1> SELECT @@SERVERNAME 2> GO ------------------------------- WOLFHOUND (1 row affected) 1> - Verify that you have checked a SQL Server 2000 server by entering:
SELECT @@VERSION GOThe osql utility returns the version information.
- Quit the osql utility by entering:
Exit