This project is read-only.

Filtering or Sorting on Custom Date Field results in no query results

Topics: Troubleshooting
May 18, 2012 at 2:54 AM

I have a custom content type "Calendar Event" which is basically a page that contains a Customer Date (date only) field named "EventDate".

When using projector, if I create a query to list all calendar events it works fine.

However as soon as I add a filter on the EventDate custom field (to exclude those in the past) or add a sort on the custom field (to sort by this date ascending), the query preview returns no results.

Has anyone else experienced this behaviour?

Jun 16, 2012 at 1:30 PM

Ok, I figured out what was going on here. All the calendar events I already had in my system prior to enabling the Projections module, and as far as I could see the Projections_FieldIndexPartRecord and Projections_IntegerFieldIndexRecord tables weren't populated with entries for my Event datetime field for these pre-existing events.

Any new events I created after enabling the projections module where listed by by query just fine as these tables were populated.

Sorry, I'm still getting my head around projections, but is there a way to regenerate this index information for pre-existing content when enabling the projections module?