title: Postgres query between two timestamps
body: <p>I am trying to request a list of 'path' between a date range.</p>
  
  <p>My DB is laid out like this:</p>
  
  <pre><code>create table mydb 
  (
  machine varchar(9),
  path varchar(350),
  in_date timestamp
  );
  </code></pre>
  
  <p>I insert data like so:</p>
  
  <pre><code>machine   | path                     | in_date
  ------------------------------------------------------------
  nodea     | /var/log/log1            | 2014-03-01 00:29:08
  nodeb     | /var/log/log1            | 2014-03-01 00:14:13
  nodea     | /var/log/log2            | 2014-03-02 00:11:11
  nodeb     | /var/log/log2            | 2014-03-02 01:10:10
  nodea     | /var/log/log2            | 2014-03-03 00:31:31
  nodea     | /var/log/log3            | 2014-03-04 19:55:12
  </code></pre>
  
  <p>What I want to pull is a list for all of the 'path' entries for nodea between two dates.
  I have tried:</p>
  
  <pre><code> select path from mydb where machine = 'nodea' and in_date between '2014-03-01 00:29:08' and '2014-03-03 00:31:31';
   select path from mydb where machine = 'nodea' and in_date &gt;= '2014-03-01 00:29:08' and in_date &lt;= '2014-03-03 00:31:31';
  </code></pre>
  
  <p>Neither of these seem to work, or they may work in a method I am not expecting and return 0 rows.</p>
  
  <p>How do I query to pull a list between the selected dates and get something like:</p>
  
  <pre><code>path
  -------------------------------
  /var/log/log1
  /var/log/log2
  /var/log/log2
  </code></pre>
  
  <p>Tnx.</p>