title: Python unnable to build query string
body: <p>I'm having trouble with the following code:</p>
  
  <pre><code>start_date = dt.datetime(2012,01,01,00,00,00)
  end_date = dt.datetime(2014,01,01,00,00,00)
  
  sql="SELECT c.id extension, er.id, flow, filename, filesize, unread, er.cr_date, callerid, \
  length, callid, info, party FROM extension_recording er, extension e, client c \
  WHERE er.extension_id = e.id AND e.client_id = c.id AND c.parent_client_id = %s \
  AND er.cr_date =&gt; %s AND er.cr_date &lt;= %s" % (client_id) (start_date) (end_date)
  
  cur.execute(sql)
  recordings = cur.fetchall()
  
  if recordings.rowcount == 0: sys.exit("No recordings for selected date range - exiting")
  
  for recording in recordings:
      do stuff to recording
  </code></pre>
  
  <p>Building the query string results in the following error:</p>
  
  <pre><code>TypeError: 'str' object is not callable
  </code></pre>
  
  <p>I'm sure I am missing something blindingly obvious, but I can't see the wood for the trees. </p>