possible bug fix for wonky metarecord count
authormiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 6 Mar 2006 19:22:54 +0000 (19:22 +0000)
committermiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Mon, 6 Mar 2006 19:22:54 +0000 (19:22 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@3269 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/metabib.pm

index f97fa01..e62cc80 100644 (file)
@@ -1395,7 +1395,7 @@ sub postfilter_search_multi_class_fts {
        my $select = <<"        SQL";
                SELECT  m.metarecord,
                        $relevance,
-                       CASE WHEN COUNT(DISTINCT rd.record) = 1 THEN MIN(m.source) ELSE 0 END,
+                       CASE WHEN COUNT(DISTINCT m.source) = 1 THEN MIN(m.source) ELSE 0 END,
                        $rank
                FROM    $search_table_list
                        $metabib_metarecord_source_map_table m,