title: sqlcmd utility returns "Could not find stored procedure"
body: <p>I am trying to execute a stored procedure using this command line utility:</p>
  
  <pre><code>sqlcmd -m 1 -S inxcert -U user1 -P u8er1 -i "D:\ESP\RunSQL.sql" -h -1 -o "D:\ESP\testoutput.txt"
  </code></pre>
  
  <p>Following is what I have written in RunSQL.sql:</p>
  
  <pre><code>exec spc.load_tables
  </code></pre>
  
  <p>Though the stored procedure exist in the database, credentials are correct and SQL Server runs fine when run from SSMS I am getting the following error in the output file:</p>
  
  <blockquote>
    <p>Msg 2812, Level 16, State 62, Server I0160SQL03\I0160SQL03, Line 1<br>
    Could not find stored procedure 'spc.mjr_vs_load_tables'.</p>
  </blockquote>
  
  <p>Please help me to learn how to resolve the error.</p>