title: Django1.6, will transaction works for raw SQL?
body: <p>Examples from offical document</p>
  
  <pre class="lang-python prettyprint-override"><code>from django.db import connection
  
  def my_custom_sql(self):
      cursor = connection.cursor()
  
      cursor.execute("UPDATE bar SET foo = 1 WHERE baz = %s", [self.baz])
  
      cursor.execute("SELECT foo FROM bar WHERE baz = %s", [self.baz])
      row = cursor.fetchone()
  
      return row
  </code></pre>
  
  <p>if update will affect select, for example</p>
  
  <pre class="lang-python prettyprint-override"><code>cursor.execute("UPDATE bar SET foo = foo + 1 WHERE baz = %s", [self.baz])
  cursor.execute("SELECT foo FROM bar WHERE baz = %s", [self.baz])
  </code></pre>
  
  <p>Does transaction works for raw SQL,  like this snap code works?</p>
  
  <pre class="lang-python prettyprint-override"><code>from django.db import connection, transaction
  
  def my_custom_sql(self):
      try:
          with transaction.atomic():
              cursor = connection.cursor()
              cursor.execute("UPDATE bar SET foo = foo + 1 WHERE baz = %s", [self.baz])
              cursor.execute("SELECT foo FROM bar WHERE baz = %s", [self.baz])
              row = cursor.fetchone()
              return row
      except IntegrityError:
          transaction.rollback()
  </code></pre>
  
  <p>Or the for the first code, begin cursor already start a transaction?</p>