Hello
I know I have to patch views to get support for subqueries, but I am a little confused.
In the thread are a lot of patches and I do not know which is the right for me.
Can anyone help me?
My Enviroment:
Lighttp, Php5.2 and Mysql 5.032 and Drupal 5.7, Views 1.6, Views_fastsearch 2.0
Currently I get following error:
user warning: Table 'temp_vfs' already exists query: CREATE TEMPORARY TABLE temp_vfs SELECT n.nid, SUM(5 * COALESCE((i.score * t.count), 0) + 2.5 * COALESCE((POW(2, GREATEST(n.created, n.changed) - 1204550213) * 6.43e-8), 0)) AS score FROM node n LEFT JOIN search_index i ON n.nid=i.sid LEFT JOIN search_total t ON i.word=t.word WHERE i.fromsid=0 AND i.word IN ('test') GROUP BY n.nid HAVING COUNT(*)=1 in /var/www/includes/database.mysqli.inc on line 151.
thx
benjamin
Comments
Comment #1
douggreen commentedUse the last patch available in the thread, currently comment #25
Comment #2
bennos commentedOk. I have used the patch in comment #25.
Now I get more errors.
* warning: mysql_get_server_info() [function.mysql-get-server-info]: Access denied for user 'www-data'@'localhost' (using password: NO) in /var/www/modules/views/views.module on line 716.
* warning: mysql_get_server_info() [function.mysql-get-server-info]: A link to the server could not be established in /var/www/modules/views/views.module on line 716.
* 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 '= temp_vfs. INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view' at line 1 query: SELECT count( DISTINCT(node.nid)) FROM node node LEFT JOIN temp_vfs temp_vfs ON . = temp_vfs. INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'content_access_rid'))) AND ( (node.type IN ('jobsuchmaschine_output','standard_job','top_job','video_job')) AND (node.status = '1') ) in /var/www/includes/database.mysqli.inc on line 151.
* 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 '= temp_vfs. INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view' at line 1 query: SELECT DISTINCT(node.nid), temp_vfs.score, node.title AS node_title, node.changed AS node_changed FROM node node LEFT JOIN temp_vfs temp_vfs ON . = temp_vfs. INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'content_access_rid'))) AND ( (node.type IN ('jobsuchmaschine_output','standard_job','top_job','video_job')) AND (node.status = '1') ) LIMIT 0, 10 in /var/www/includes/database.mysqli.inc on line 151.
* warning: mysql_get_server_info() [function.mysql-get-server-info]: Access denied for user 'www-data'@'localhost' (using password: NO) in /var/www/modules/views/views.module on line 716.
* warning: mysql_get_server_info() [function.mysql-get-server-info]: A link to the server could not be established in /var/www/modules/views/views.module on line 716.
* user warning: Table 'temp_vfs' already exists query: CREATE TEMPORARY TABLE temp_vfs SELECT n.nid, SUM(5 * COALESCE((i.score * t.count), 0) + 2.5 * COALESCE((POW(2, GREATEST(n.created, n.changed) - 1204574497) * 6.43e-8), 0)) AS score FROM node n LEFT JOIN search_index i ON n.nid=i.sid LEFT JOIN search_total t ON i.word=t.word WHERE i.fromsid=0 AND i.word IN ('vertrieb') GROUP BY n.nid HAVING COUNT(*)=1 in /var/www/includes/database.mysqli.inc on line 151.
* user warning: Unknown column 'temp_vfs.score' in 'field list' query: SELECT DISTINCT(node.nid), temp_vfs.score 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_hierarchy term_hierarchy2 ON term_hierarchy.parent = term_hierarchy2.tid LEFT JOIN term_node term_node2 ON node.nid = term_node2.nid LEFT JOIN term_hierarchy term_hierarchy3 ON term_node2.tid = term_hierarchy3.tid LEFT JOIN term_hierarchy term_hierarchy4 ON term_hierarchy3.parent = term_hierarchy4.tid LEFT JOIN term_hierarchy term_hierarchy5 ON term_hierarchy4.parent = term_hierarchy5.tid LEFT JOIN term_hierarchy term_hierarchy6 ON term_hierarchy5.parent = term_hierarchy6.tid LEFT JOIN term_node term_node3 ON node.nid = term_node3.nid LEFT JOIN term_hierarchy term_hierarchy7 ON term_node3.tid = term_hierarchy7.tid LEFT JOIN term_hierarchy term_hierarchy8 ON term_hierarchy7.parent = term_hierarchy8.tid LEFT JOIN term_hierarchy term_hierarchy9 ON term_hierarchy8.parent = term_hierarchy9.tid INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'content_access_rid'))) AND ( (node.status = '1') AND (node.type IN ('standard_job','top_job')) AND (term_node.tid IN ('') OR term_hierarchy2.tid IN ('')) AND (term_node2.tid IN ('') OR term_hierarchy4.tid IN ('') OR term_hierarchy5.tid IN ('') OR term_hierarchy6.tid IN ('')) AND (term_node3.tid IN ('') OR term_hierarchy8.tid IN ('') OR term_hierarchy9.tid IN ('')) ) LIMIT 0, 5 in /var/www/includes/database.mysqli.inc on line 151.
Any help would be great?
thx
benjamin