I'm running Drupal 5 with everything up to date as far as I know. I have been using a content type called "event" which included a CCK date field. I didn't like how for events with multiple dates it would list all the dates in the teaser, which looks kind of messy, so I deleted the date field from my content type "event." Now on every page I get the following error:
user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'ASC LIMIT 0, 1' at line 1 query: SELECT node.nid, node.sticky AS node_sticky, field_date_value FROM node node LEFT JOIN term_node term_node ON node.nid = term_node.nid LEFT JOIN term_hierarchy term_hierarchy ON term_node.tid = term_hierarchy.tid LEFT JOIN term_data term_data ON term_hierarchy.parent = term_data.tid LEFT JOIN term_hierarchy term_hierarchy2 ON term_data.tid = term_hierarchy2.tid LEFT JOIN term_data term_data2 ON term_hierarchy2.parent = term_data2.tid LEFT JOIN event event ON node.nid = event.nid LEFT JOIN i18n_node i18n ON node.nid = i18n.nid WHERE (i18n.language ='en' OR i18n.language ='' OR i18n.language IS NULL) AND ( (node.status = '1') AND (term_node.tid = '24' OR term_data.tid = '24' OR term_data2.tid = '24') AND (event.event_start >= (1168990609 + 0)) ) ORDER BY node_sticky DESC, ASC LIMIT 0, 1 in /home/cpelham/public_html/drupal/includes/database.mysql.inc on line 167.
I thought it might be from my views so I went through my views and removed the date field as a filter criteria , bit I still get the error message. Next I tried uninstalling the date module and then the CCK module itself, but I still get the errors. Is there any way to rescue my site? I hope I don't have to throw away my database and start all over! Help!
our web site is
Comments
Comment #1
karens commentedThat's a Views query, so somewhere you have a view that still is trying to use the date field, maybe as a sort or filter or in an argument. You'll need to pull up your views and check closely to find which one it is and remove the field. This is already noted as a CCK issue -- that deleted fields may still exist in various views and fixing that is something that has to be done in CCK core.