title: SQLite - Can we pass arguments to a .sql file from batch file?
body: <p>I would like to pass an argument from a batch file to SQL file(for SQLite). I had no luck finding this method online, is it possible to do? If not, is there any alternative way?</p>
  
  <p>For example, here is what I wanted to do:</p>
  
  <p>In batch file I wanted to pass <code>%arg1%</code> to <code>sqlTest.sql</code>:</p>
  
  <pre><code>@echo off
  set arg1=%1
  echo .quit | sqlite3.exe -init sqlTest.sql %arg1%"
  </code></pre>
  
  <p>In sqlTest.sql file:</p>
  
  <pre><code>.open "db/code_status.db"
  SELECT FileName, FilePath, Author
  FROM CodeStatus
  LEFT JOIN CodeFile ON CodeStatus.ChangeId = CodeFile.ChangeId
  WHERE WorkItemId = 2197
  ORDER BY ModifiedDate ASC;
  </code></pre>
  
  <p>For  <code>WHERE WorkItemId = 2197</code>, I would like to replace <code>2197</code> to the argument value from batch.</p>
  
  <p>Any solution?, thanks!</p>