title: Concurrently Adding Entries to Database Raises Timestamp Uniqueness Issue
body: <p>I have multiple scripts that are entering data into the same database. An issue that I encounter is that before getting too far, generally one of the programs crash, and the reason for that is that there appears to be a duplicate timestamp entry. </p>
  
  <pre><code>Message: '&lt;class \'psycopg2.IntegrityError\'&gt;: duplicate key value violates unique constraint "timestamp_key"\nDETAIL:  Key ("timestamp")=(2016-09-12 16:23:51.171562+00) already exists.\n'
  Arguments: ()
  </code></pre>
  
  <p>Basically, the two programs attempted to make an entry at precisely the same time. Since the timestamp is supposed to be unique, this causes an issue, and the script just stops at this point. </p>
  
  <p>I'm wondering if there is a way to do this concurrently. Would it be possible to make the time stamp more precise and therefore much less likely that it would conflict? Or are there other options that would be better in this case? </p>