This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit ezplatform.com

eZ Community » Learn » eZ Publish » Need for speed - How to use eZ Find...

Need for speed - How to use eZ Find search fetch instead of standard content list/tree fetch

Tuesday 13 July 2010 10:27:45 am

  • Currently 5 out of 5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Step 2: Understanding eZ Find’s fetch function for search

In fact, the eZ Find search function is still using database but only for fetching node data after search result list is returned by Solr. SQL queries for getting node data are rather fast and do not present a real problem. Results are dependent on user rights so we don’t need to worry about access privileges also.

Main characteristics of the search template function :

  • It can search text with in all indexed fields (query parameter)
  • There are offset and limit parameters for paging (offset & limit parameters)
  • There is a sort parameter (sort_by parameter). Default sort is relevance based, but other sorting can be used also.
  • Facets enable drill-down possibilities (facet parameter)
  • Filtering with multi nesting conditions on all attributes and meta data (filter parameter)
  • Special class parameter for filtering more classes (class_id parameter)
  • Subtree array parameter for filtering one or more subtrees (subtree_array parameter)
  • Special section parameter for filtering on sections (section_id parameter)
  • Ignore visibility parameter to disable or enable of searching hidden nodes (ignore_visibility parameter)
  • Limitation parameter for overriding current user access limits (limitation parameter)

There is no parameter for fetching list (instead of tree) but it can be easily achieved with filter. It is possible to search within more than one parent node. Results can be sorted by relevance, by meta-data or by attributes. Filter can be built with mix of nested “AND” and “OR” conditions.

The most important gain, if the eZ Find search function is used, is the possibility to combine filtering with powerful text search. And there are lot of bonus features that can be used also: highlighting , spellchecking, etc

 

Printable

Printer Friendly version of the full article on one page with plain styles

Author(s)

Proudly Developed with from