improve performance of multi-class searches
authorgmc <gmc@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 24 Jan 2011 18:42:13 +0000 (18:42 +0000)
committergmc <gmc@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 24 Jan 2011 18:42:13 +0000 (18:42 +0000)
commit09e4b9d134fe9de6f22c7942929b848ddc7e6347
tree6aa193a5667b218eb86f60576c2fafa81f4e4918
parent8078f0a2ede35a56aae381f8b310b5b38f55f1c4
improve performance of multi-class searches

Backport of trunk commit 18233.

For as yet unknown reasons, Postgres sometimes uses
nested loops instead of hash joins when joining subqueries
in a multi-class bib search.  This can result in searches
such as "author:rowling title:harry potter" never completing.

Removing the interior limit clause can both speed up the query
and make search results more accurate when combining queries
of two or more common words.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_1_6@19263 dcc99617-32d9-48b4-a31d-7c20da2025e4
Open-ILS/src/sql/Pg/300.schema.staged_search.sql