Fraudulent Upvotes
We’re given three tables representing a forum of users and their comments on posts.
We want to figure out if users are creating multiple accounts to upvote their own comments.
What kind of metrics could we use to figure this out?
Write a query that could display the percentage of users on our forum that would be acting fraudulently in this manner.
Example:
Input:
users
table
Column | Type |
---|---|
id |
INTEGER |
created_at |
DATETIME |
username |
VARCHAR |
comments
table
Column | Type |
---|---|
id |
INTEGER |
created_at |
DATETIME |
post_id |
INTEGER |
user_id |
INTEGER |
comment_votes
table
Column | Type |
---|---|
id |
INTEGER |
created_at |
DATETIME |
user_id |
INTEGER |
comment_id |
INTEGER |
is_upvote |
BOOLEAN |
.....
Loading editor