title: sqlcmd how to run a query against specific database?
body: <p>so this is the query that i want to run </p>
  
  <pre><code>sqlcmd -E -S localhost\MSSQLSERVER_2016 -i C:\Tables.sql
  </code></pre>
  
  <p>I have multiple databases in this instance and when the command above runs, i have no idea which database it runs the query against.
  Is there any way that i can use sqlcmd to run against a database that i want it to run?</p>
  
  <p>i have also tried </p>
  
  <pre><code>sqlcmd -E -S localhost\MSSQLSERVER_2016.mydatabase -i C:\Tables.sql
  </code></pre>
  
  <p>but that didn't work.</p>