title: PostgreSQL syntax check without running the query
body: <p>I want to verify the syntax of files containing sql queries before they can be committed in my CVS project.</p>
  <p>In order to do that, I have a commitinfo script, but I have trouble finding out if the sql commands are valid. <code>psql</code> does not seem to have a dryrun mode, and constructing my own postgresql-dialact tester from the grammar (that is in the source) seems like a long stretch.</p>
  <p>The scripts may contain multiple queries, so an <code>EXPLAIN</code> cannot be wrapped around them.</p>
  <p>Any hints?</p>