I have content type which have date field(multiple). It also collect the end date.
Now I am creating a view which will list the nodes of that content type.
It will sort the nodes with the start date in ascending order. And only those nodes will display whose start date is greater than the current date.
I have added the filter of start date. If start date is greater than the current date. The option Add multiple value identifier
is set to Yes
in the filter settings.
In the query settings I Distinct and pure distinct is checked. I have also tried the aggregation but still the view returns duplicate results.
Any Idea how will remove the dupliation?
EDIT
This is the sql query that view generates
SELECT DISTINCT node.title AS node_title, node.nid AS nid, field_data_field_event_date_time.field_event_date_time_value AS field_data_field_event_date_time_field_event_date_time_value, node.created AS node_created, 'node' AS field_data_field_event_date_time_node_entity_type
FROM
{node} node
LEFT JOIN {field_data_field_event_date_time} field_data_field_event_date_time ON node.nid = field_data_field_event_date_time.entity_id AND (field_data_field_event_date_time.entity_type = 'node' AND field_data_field_event_date_time.deleted = '0')
WHERE (( (node.status = '1') AND (node.type IN ('event')) AND (DATE_FORMAT(ADDTIME(field_data_field_event_date_time.field_event_date_time_value, SEC_TO_TIME(-25200)), '%Y-%m-%d\T%H:%i') >= '2014-05-15T22:19') ))
ORDER BY field_data_field_event_date_time_field_event_date_time_value ASC, node_created DESC
LIMIT 10 OFFSET 0
The problem is if an event has 2 dates then it is displaying two times and if it has 3 dates then it is displaying 3 times in the results.