Dan,

Thanks again for this great module. (I'm using 6.x-1.21)

I had this working well but an update seems to have broken things...

I have a little local 'Bed and breakfast' listings site and need your 'Finder' to facilitate users to search for the facilities they need: Double room, single room, ensuite etc.

I have a vocabulary set up with all the relevant tags.

I have a 'View' set up which displays all nodes which are tagged with the relevant vocabulary. I then want a 'Finder' with a checkbox for each tag and a submit button to display a sub-section of the view.

I don't see any of the checkboxes at all, just all the results, unfiltered.

This is the exported Finder:

array(
  'finder_id' => '4',
  'base' => 'views',
  'title' => 'Silverstone Accommodation Search',
  'description' => 'Silverstone Accommodation Search',
  'path' => 'silverstone_accommodation_search',
  'block' => '0',
  'settings' => array(
    'form_on_page' => 1,
    'form' => array(
      'prefix' => '',
      'prefix_format' => '1',
      'suffix' => '',
      'suffix_format' => '1',
      'button_text' => 'Find',
      'go_text' => 'Go',
    ),
    'advanced' => array(
      'no_results' => array(
        'no_results' => 'There are no results to display',
      ),
      'filter' => 1,
      'validate_empty' => 1,
      'submission' => 1,
      'ahah' => 1,
      'ahah_effect' => 'none',
      'ahah_remote' => 0,
      'element_combination' => '0',
      'pager' => '0',
      'goto' => '',
      'hide_args' => 0,
      'arg_sep' => ',',
      'empty_symbol' => '',
      'show_links' => 1,
      'show_admin_links' => 1,
      'cache_finder_find' => '0',
      'search' => '0',
      'search_tab' => 'node',
    ),
    'views' => array(
      'view' => 'all_silverstone_accommodation',
      'displays' => array(
        'query' => 'default',
        'output' => 'default',
      ),
      'results' => '0',
      'views_args' => array(
        'args' => '',
        'delimiter' => '/',
      ),
      'empty_text' => 1,
    ),
  ),
  'elements' => array(
    '0' => array(
      'finder_element_id' => '4',
      'finder_id' => '4',
      'element' => 'buttons',
      'title' => 'Tick the boxes for the facilities you require. **Scroll down for results**',
      'weight' => '0',
      'settings' => array(
        'form' => array(
          'description' => '',
          'prefix' => '',
          'prefix_format' => '1',
          'suffix' => '',
          'suffix_format' => '1',
          'default_value' => '',
          'required' => 1,
          'multiple' => 1,
          'empty' => '',
          'empty_text' => '',
        ),
        'choices' => array(
          'field' => array(
            'term_data_1.name' => 'term_data_1.name',
          ),
          'rewrite' => array(
            'php' => '',
          ),
          'displays' => array(
            'query' => 'default',
          ),
          'views' => array(
            'args' => '',
            'delimiter' => '/',
          ),
        ),
        'advanced' => array(
          'delimit' => '',
          'field_combination' => '0',
          'value_combination' => '0',
          'nesting_order' => '0',
          'match' => 'e',
        ),
      ),
      'element_handler' => array(
        '#title' => 'Check boxes/radio buttons',
        '#module' => 'finder_optionwidgets',
      ),
      '#_finder_object' => '1',
    ),
  ),
  'elements_index' => array(
    '4' => 0,
  ),
  'base_handler' => array(
    '#title' => 'Views finder',
    '#module' => 'finder_views',
  ),
  'admin_links' => array(
    'silverstone_accommodation_search' => 'View \"Path\"',
    'admin/build/finder/4/edit' => 'Edit',
  ),
  'links' => array(),
  '#_finder_object' => '1',
)

Can you help me past this? Can't understand what I'm doing wrong...

Let me know if you need more info to troubleshoot...

Thanks :-)

S

Comments

SMartin’s picture

Now I'm also getting the 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 ') ORDER BY _random ASC' at line 17 query: SELECT node.nid AS nid, term_data_1.name AS term_data_1_name, term_data_1.vid AS term_data_1_vid, term_data_1.tid AS term_data_1_tid, RAND() AS _random, finder_table_2.name AS finder_field_1, finder_table_2.name AS finder_field_1_matched FROM node node LEFT JOIN term_node term_node ON node.vid = term_node.vid LEFT JOIN term_data term_data ON term_node.tid = term_data.tid LEFT JOIN term_data term_data_1 ON term_node.tid = term_data_1.tid AND term_data_1.vid = 1 LEFT JOIN term_node finder_table_3 ON node.vid = finder_table_3.vid LEFT JOIN term_data finder_table_2 ON finder_table_3.tid = finder_table_2.tid AND finder_table_2.vid = 1 WHERE ((node.status = 1) AND (term_data.vid in ('1'))) AND (1=1) AND (finder_table_2.name IS NOT NULL) AND () ORDER BY _random ASC in /home/dotcamer/public_html/trackrooms.co.uk/sites/all/modules/views/includes/view.inc on line 814.
danielb’s picture

Category: support » bug

This is a bug! Really sorry about this!!

danielb’s picture

Priority: Normal » Critical
danielb’s picture

Version: 6.x-1.9 » 6.x-1.21
danielb’s picture

A fix will be forthcoming, I have the code, but there is a slight complication in getting a release out.

danielb’s picture

Status: Active » Closed (duplicate)
SMartin’s picture

Dan,

I applied the fix you linked to and ran update.php and cron but I still get:

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 ') ORDER BY _random ASC' at line 17 query: SELECT node.nid AS nid, term_data_1.name AS term_data_1_name, term_data_1.vid AS term_data_1_vid, term_data_1.tid AS term_data_1_tid, RAND() AS _random, finder_table_2.name AS finder_field_1, finder_table_2.name AS finder_field_1_matched FROM node node LEFT JOIN term_node term_node ON node.vid = term_node.vid LEFT JOIN term_data term_data ON term_node.tid = term_data.tid LEFT JOIN term_data term_data_1 ON term_node.tid = term_data_1.tid AND term_data_1.vid = 1 LEFT JOIN term_node finder_table_3 ON node.vid = finder_table_3.vid LEFT JOIN term_data finder_table_2 ON finder_table_3.tid = finder_table_2.tid AND finder_table_2.vid = 1 WHERE ((node.status = 1) AND (term_data.vid in ('1'))) AND (1=1) AND (finder_table_2.name IS NOT NULL) AND () ORDER BY _random ASC in /home/dotcamer/public_html/trackrooms.co.uk/sites/all/modules/views/includes/view.inc on line 814.

Can I give any other info to help you?

S

danielb’s picture

I posted the wrong file.

SMartin’s picture

Dan,

Is the correct file there now...?

S

SMartin’s picture

Issue summary: View changes

Revised version