title: Thinking Sphinx without records within date range error
body: <p>im trying to find records that are NOT created in a certain date range using a thinking sphinx query in my rails 4 project with postgresql as database</p>
  
  <p>THIS WORKS</p>
  
  <pre><code>Housing.search "some text",
  star: true, 
  ranker: :bm25, 
  with: {created_at (3.weeks.ago..Time.zone.now)}
  </code></pre>
  
  <p>BUT THIS DOESN´T</p>
  
  <pre><code>Housing.search "some text",
  star: true,
  ranker: :bm25,
  without: {created_at:(3.weeks.ago..Time.zone.now)}
  </code></pre>
  
  <p>I´m thinking its a bug in the query since it finds all record within the given date range, but fails to find the opposite?</p>
  
  <p>This is my gemfile</p>
  
  <pre><code>gem 'mysql2', '0.3.12b4'
  gem 'thinking-sphinx', github: 'pat/thinking-sphinx'
  gem 'flying-sphinx', github: 'flying-sphinx/flying-sphinx'
  gem 'delayed_job_active_record', '&gt;= 4.0.0.beta2'
  gem 'delayed_job_web'
  gem 'ts-delayed-delta', github: 'pat/ts-delayed-delta'
  </code></pre>
  
  <p>This is my housing_indices</p>
  
  <pre><code>ThinkingSphinx::Index.define :housing, :with =&gt; :active_record, :delta =&gt; ThinkingSphinx::Deltas::DelayedDelta do
    has created_at
    &lt; + OTHER FIELDS THAT ARE INDEXED &gt;
    set_property :enable_star =&gt; true
    set_property :min_infix_len =&gt; 1
    set_property :html_strip =&gt; true
    set_property :charset_type =&gt; "utf-8"
  end
  </code></pre>
  
  <p>this is the query from the log when using without: {created_at:(3.weeks.ago..Time.zone.now)}</p>
  
  <pre><code>  Sphinx Query (1.0ms)  SELECT * FROM `housing_core`, `housing_delta` WHERE MATCH('@location_name *Krimml*') AND max_capacity BETWEEN 1 AND 1000 AND number_of_bathrooms BETWEEN 1 AND 3 AND number_of_bed_places BETWEEN 2 AND 10 AND sphinx_deleted = 0 AND created_at &lt; 1376554070 OR created_at &gt; 1378368470 AND activated_at &lt;&gt; 0 LIMIT 0, 20 OPTION ranker=bm25
  </code></pre>
  
  <p>And this Is the error I am getting</p>
  
  <pre><code>sphinxql: syntax error, unexpected OR, expecting $end near 'OR created_at &gt; 1378368470 AND   activated_at &lt;&gt; 0 LIMIT 0, 20 OPTION ranker=bm25; SHOW META'
  </code></pre>
  
  <p>this is the query from the log when using with: {created_at:(3.weeks.ago..Time.zone.now)}</p>
  
  <pre><code>Sphinx Query (3.9ms)  SELECT * FROM `housing_core`, `housing_delta` WHERE MATCH('@location_name *Krimml*') AND created_at BETWEEN 1376555152 AND 1378369552 AND max_capacity BETWEEN 1 AND 1000 AND number_of_bathrooms BETWEEN 1 AND 3 AND number_of_bed_places BETWEEN 2 AND 10 AND sphinx_deleted = 0 AND activated_at &lt;&gt; 0 LIMIT 0, 20
  </code></pre>
  
  <p>so i think what I´m looking for is this query to be executed</p>
  
  <pre><code>AND created_at NOT BETWEEN 1376555152 AND 1378369552
  </code></pre>