title: sqlcmd error Unclosed quotation mark
body: <p>I want to restore sql server db from sql server 2012 to sql server 2008 R2 using SQLCMD.</p>
  
  <p>sqlcmd -S localhost -E -I -d abc -i d:\db\abc.sql >> ran fine till 33399 rows. The abc.sql is 3.4 GB in size.</p>
  
  <pre><code> Msg 105, Level 15, State 1, Server SERVER1, Line 590
      Unclosed quotation mark after the character string '
      &lt;h1 class="calibre18" id="calibre_pb_1"&gt;&lt;span class="blah blah....
  </code></pre>
  
  <p>I have no idea how to get it to restore. The file is so huge, generated with sqlserver 2012 management studio with option <strong>script for server 2008 R2</strong>  , schema with data.</p>
  
  <p>I cannot detach/attach or restore directly from abc.bak because of the version compatibility problem. I can't even edit the file manually.</p>
  
  <p>Also, i tried generate the db relationship with the script (schema only), then use SSMS Export data => duplicate identity</p>