title: How do I get the "id" after INSERT into MySQL database with Python?
body: <p>I execute an INSERT INTO statement</p>
  
  <pre><code>cursor.execute("INSERT INTO mytable(height) VALUES(%s)",(height))
  </code></pre>
  
  <p>and I want to get the primary key.</p>
  
  <p>My table has 2 columns: </p>
  
  <pre><code>id      primary, auto increment
  height  this is the other column.
  </code></pre>
  
  <p>How do I get the "id", after I just inserted this? </p>