evergreen.located_uris() returns a rank, and we should use it
authorMike Rylander <mrylander@gmail.com>
Thu, 12 Dec 2013 22:08:17 +0000 (17:08 -0500)
committerJeff Godin <jgodin@tadl.org>
Mon, 17 Feb 2014 17:36:35 +0000 (12:36 -0500)
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Jeff Godin <jgodin@tadl.org>
Open-ILS/src/sql/Pg/990.schema.unapi.sql

index f819c64..88ef311 100644 (file)
@@ -462,7 +462,7 @@ RETURNS XML AS $F$
                         FROM evergreen.ranked_volumes($1, $2, $4, $6, $7, $9, $5) AS y
                         UNION ALL
                         -- Located URIs
-                        SELECT unapi.acn(uris.id,'xml','volume',evergreen.array_remove_item_by_value( evergreen.array_remove_item_by_value($5,'holdings_xml'),'bre'), $3, $4, $6, $7, FALSE), 0, name, label_sortkey
+                        SELECT unapi.acn(uris.id,'xml','volume',evergreen.array_remove_item_by_value( evergreen.array_remove_item_by_value($5,'holdings_xml'),'bre'), $3, $4, $6, $7, FALSE), uris.rank, name, label_sortkey
                         FROM evergreen.located_uris($1, $2, $9) AS uris
                      )x)
                  ),