title: Error PostgreSQL delete with INNER JOIN
body: <h1>Postgres 8.4</h1>
  <pre><code>DELETE
  FROM processing_transaction AS pt 
  INNER JOIN processing_transaction_movement AS ptm 
  ON pt.processing_transaction_id = ptm.processing_transaction_id
  LEFT OUTER JOIN test_package tesp ON pt.test_package_id = tesp.test_package_id
  LEFT OUTER JOIN test_batch tbat On tesp.test_batch_id = tbat.test_batch_id
  WHERE pt.processing_transaction_type = 'TEST';
  </code></pre>
  <p>I get following error:</p>
  <blockquote>
  <p>ERROR:  syntax error at &gt;&gt;INNER&lt;&lt;
  LINE 1: DELETE FROM processing_transaction AS pt INNER JOIN processi...</p>
  </blockquote>
  <p>Please could you help me to find the error in my SQL-query</p>
  <hr />
  <p>Thank you for your support @desislavkamenov @jan.
  Now I used this:</p>
  <blockquote>
  <p>BEGIN WORK;</p>
  <p>DELETE
  FROM processing_transaction AS pt
  USING processing_transaction_movement AS ptm, test_package tesp, test_batch tbat
  WHERE pt.processing_transaction_type = 'TEST';
  AND pt.processing_transaction_id = ptm.processing_transaction_id
  AND pt.test_package_id = tesp.test_package_id
  AND tesp.test_batch_id = tbat.test_batch_id</p>
  <p>ROLLBACK;</p>
  </blockquote>
  <p>But I need to delete data from two tables <b>(processing_transaction and processing_transaction_movement)</b> , I have looking for somethink like that and found out that I can do it with &quot;ON DELETE CASCADE&quot;. But I don´t know how to use this here.
  So Please help me again.</p>