using last id for lead record, instead of first
authormiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 7 Jul 2005 13:11:47 +0000 (13:11 +0000)
committermiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 7 Jul 2005 13:11:47 +0000 (13:11 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@1088 dcc99617-32d9-48b4-a31d-7c20da2025e4

Evergreen/src/extras/import/quick_metarecord_map.sql

index 9094ab6..96202e0 100644 (file)
@@ -6,7 +6,7 @@ TRUNCATE metabib.metarecord;
 TRUNCATE metabib.metarecord_source_map;
 
 INSERT INTO metabib.metarecord (fingerprint,master_record)
-       SELECT  fingerprint,min(id)
+       SELECT  fingerprint,max(id)
          FROM  biblio.record_entry
          WHERE fingerprint IS NOT NULL
          GROUP BY 1;