Skip to content

Commit

Permalink
Fix table
Browse files Browse the repository at this point in the history
  • Loading branch information
AlbertMarashi committed Jul 17, 2024
1 parent d51f9cf commit 1c2544c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions database_schema.surql
Original file line number Diff line number Diff line change
Expand Up @@ -164,8 +164,8 @@ DEFINE INDEX compound_unique_statement_vote ON TABLE statement_vote COLUMNS user
-- DEBATE SCORING AND VIEWS --
------------------------------

REMOVE TABLE ranked_statements;
REMOVE TABLE scored_statements;
-- REMOVE TABLE ranked_statements;
-- REMOVE TABLE scored_statements;

DEFINE TABLE ranked_statement AS
SELECT
Expand All @@ -179,7 +179,7 @@ DEFINE TABLE scored_statement AS
SELECT
*,
fn::calc_score(total_votes, rating_avg) AS score
FROM ranked_statements;
FROM ranked_statement;

DEFINE FUNCTION fn::calc_score($vote_count: number, $average_rating: number) {
RETURN function($vote_count, $average_rating) {
Expand Down

0 comments on commit 1c2544c

Please sign in to comment.