This is an obsolete, yet a powerful tool to test access to a given database server or to do some more complex stuff like building or populating a database.
It’s a fast, easy way to access the database while working with SQL Server without needing SQL Server Management Studio to install.
OSQL was replaced with a new utility called SQLCMD
SQLCMD has many advantages as below:
- SQLCMD supports parameterized variables
- SQLCMD support Customized editor
- :XML [ONOFF]
- :Error STDERRSTDOUT
- :Perftrace STDERRSTDOUT
- Remote Dedicated Admin Connection (DAC)
Still lacks a few things that OSQL had, one of the important things was the way data could be exported into CSV without the count, making the CSV file usable as it was exported.
Install SQL Server 2012 (SP1) Express
If you don’t want to install SQL Server 2012 (SP1) Express, you may use this workaround to just install OSQL :