Skip to content

Commit

Permalink
Ensure project page hit records get canonicalised in db upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
bennuttall committed Sep 17, 2020
1 parent f629583 commit 5dc6a17
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions piwheels/initdb/sql/update_piwheels_0.17_to_0.18.sql
Original file line number Diff line number Diff line change
Expand Up @@ -203,3 +203,6 @@ $sql$;

REVOKE ALL ON FUNCTION get_package_aliases(TEXT) FROM PUBLIC;
GRANT EXECUTE ON FUNCTION get_package_aliases(TEXT) TO {username};

UPDATE project_page_hits
SET package = regexp_replace(LOWER(package), '[_.-]+', '-', 'g');

0 comments on commit 5dc6a17

Please sign in to comment.