I'm trying to set up sorting by date in the faceted search configuration and get the following error:
user warning: Unknown column 'field_date_month' in 'order clause' query: SELECT DISTINCT(n.nid) AS nid, COUNT(DISTINCT(n.nid)) AS count, YEAR(content_field_date.field_date_value) AS field_date_year FROM node AS n INNER JOIN content_field_date AS content_field_date ON n.vid = content_field_date.vid WHERE ((n.status = 1) AND (n.type IN ('image')) AND (content_field_date.field_date_value IS NOT NULL) AND (n.type IN ('image'))) AND n.nid IN (SELECT DISTINCT(node.nid) FROM node node LEFT JOIN content_field_date node_data_field_date ON node.vid = node_data_field_date.vid LEFT JOIN content_type_image node_data_field_image ON node.vid = node_data_field_image.vid WHERE (node.status = '1') AND (node.type IN ('image')) ) GROUP BY field_date_year ASC ORDER BY field_date_year ASC, field_date_month ASC, field_date_day ASC LIMIT 0, 21 in /home/etcclean/public_html/includes/database.mysql.inc on line 172.
Sorting by count works fine, but I would like to sort date fields by date. The page can be found here. The site is running Drupal 5.3.
Comments
Comment #1
david lesieur commentedComment #2
david lesieur commentedThis has been fixed recently.
Comment #3
david lesieur commentedActually, this was a duplicate of http://drupal.org/node/229610.