title: Postgresql Database Backup Using Python
body: <p>I would like to backup database using Python code. I want to backup some tables of related data. How to backup and how to choose desired tables using "SELECT" statement?</p>
  
  <p>e.g.</p>
  
  <p>I want to get data from 2014-05-01 to 2014-05-10 of some tables and output this result as .sql extension file</p>
  
  <p>How can I get this format using python code?
  If you don't mind, please explain.
  Thanks.</p>