title: How to compare date (month/year) with another date (month/year)
body: <p>How to compare parts of date in Informix DBMS:</p>
  
  <p>I wrote the following query but I get a syntax error:</p>
  
  <pre><code>select id,name from h_history 
   where ( h_date::DATETIME YEAR TO MONTH &gt;= 2/2012 )
     and ( h_date::DATETIME YEAR TO MONTH &lt;= 1/2013 )
  </code></pre>
  
  <p>I wanna to compare with year and month </p>
  
  <p>How to do this?</p>