title: Nested transaction rollback between two savepoints?
body: <p>For the three SQL types (MySql, SQLite and PostgreSQL) I want / need to handle save points identically.</p>
  
  <p>Now I have my application to change different entries in the database in one big transaction and need some nested transactions for special behavior of the program.</p>
  
  <p>So the question is, if i create something like:</p>
  
  <pre><code>BEGIN TRANSACTION;
  --random insert/update statements
  SET SAVEPOINT sp1;
  --more random inserts/updates
  SET SAVEPOINT sp2;
  --inserts n stuff
  </code></pre>
  
  <p>(yes the syntax may not be correct, its just an example)</p>
  
  <p>So i want to know if it is possible to do a rollback between the two save points <code>sp1</code> and <code>sp2</code> without rolling back the inserts/updates after <code>sp2</code>?</p>