Thinking Sphinx indexing non-expired records
https://stackoverflow.com/questions/436966
No correct solution
OTHER TIPS
The easiest approach is adding the following statement to your define_index block:
where "expired_at >= NOW()"
That's the MySQL version, anyway. PostgreSQL will be pretty similar:
where "expired_at >= current_timestamp"
Although, I'm no PostgreSQL expert, but hopefully that's close enough to what's needed.
Cheers
PostgreSQL also accepts the function 'now()'
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow