libertysoft3 / saidit

The reddit open source fork powering SaidIt
https://saidit.net
Other
226 stars 40 forks source link

Getting subreddit name from the cassandra db? #107

Closed trident765 closed 2 years ago

trident765 commented 2 years ago

I am trying to find what subreddits are muted the most.

I do:

cqlsh:reddit> select * from "SubredditMutesByAccount";

 key | column1 | value
-----+---------+-------
   2 |       1 |
   2 |       2 |
   2 |       4 |

This tells me the ids of subreddits are muted, but this is of little use to me if I do not know the subreddit names. How can I find the names of the subreddits that are muted?

libertysoft3 commented 2 years ago

fetch the sub names from postgres. you have to watch out for base10 vs base36 ids too.

trident765 commented 2 years ago

Thanks it worked.