Remove controversial migration, let admins run in manually

This commit is contained in:
Felix Ableitner 2024-10-30 10:10:29 +01:00
parent cdc1cf3bf7
commit 47e84b274c
2 changed files with 0 additions and 34 deletions

View file

@ -1,17 +0,0 @@
UPDATE
post_aggregates
SET
controversy_rank = CASE WHEN downvotes <= 0
OR upvotes <= 0 THEN
0
ELSE
(upvotes + downvotes) * CASE WHEN upvotes > downvotes THEN
downvotes::float / upvotes::float
ELSE
upvotes::float / downvotes::float
END
END
WHERE
upvotes > 0
AND downvotes > 0;

View file

@ -1,17 +0,0 @@
UPDATE
post_aggregates
SET
controversy_rank = CASE WHEN downvotes <= 0
OR upvotes <= 0 THEN
0
ELSE
(upvotes + downvotes) ^ CASE WHEN upvotes > downvotes THEN
downvotes::float / upvotes::float
ELSE
upvotes::float / downvotes::float
END
END
WHERE
upvotes > 0
AND downvotes > 0;