Permalink
Browse files

Only index the most recently pushed version of each jar. #57

  • Loading branch information...
1 parent 0934c42 commit 7885732371b62d4d9f0e39fddf2d2385558ec859 @ato ato committed Jul 28, 2012
Showing with 9 additions and 8 deletions.
  1. +9 −8 tools/reindex.sql
View
17 tools/reindex.sql
@@ -11,12 +11,13 @@
begin;
delete from search;
insert into search (id, jar_name, group_name, content)
- select new.id, new.jar_name, new.group_name,
- new.jar_name || ' ' ||
- new.group_name || ' ' ||
- new.version || ' ' ||
- coalesce(new.authors, '') || ' ' ||
- new.user || ' ' ||
- coalesce(new.description, '')
- from jars new;
+ select id, jar_name, group_name,
+ jar_name || ' ' ||
+ group_name || ' ' ||
+ version || ' ' ||
+ coalesce(authors, '') || ' ' ||
+ user || ' ' ||
+ coalesce(description, '')
+ from jars
+ group by group_name, jar_name;
commit;

0 comments on commit 7885732

Please sign in to comment.