Connecting to SQL Server via a bat file

  • I am new to SQL Server and wonder if there is a way to connect to SQL Server to query data via a bat file. I know I can use SQLPLUS for Oracle, what about SQL Server?

    Thanks!

  • Using isql command, you can connect to sqlserver

  • Are you using 2005? I'm in the process of learning for switching from 2000 but according to 2005 BOL, isql is no longer supported and sqlcmd should be is used for 2005. isql is even old for 2000 but can be used. osql is the tool the supports all the features of 2000.

    Steve

  • osql for SQL Server 2000 and SQLCMD for SQL Server 2005 are what you should use.

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply