-10

How to search infavorites of not mine?

Just curios to know how to search favorites of jeff-atwood if he has? infavorites:1 redirects to mine

7

1 Answer 1

3

You can only do that with the Stack Exchange Data Explorer.

The Votes table holds the favorite vote from a user in rows with votetypeid = 5. That row is one of the rows that isn't sanitized for userid's. Within that set you can limit your search scope but if you're down to searching in the body you might hit limitations as text search on SEDE is slow and a query needs to produce results within 2 minutes.

Here is an example query to get you started:

select top 100
       postid as [Post Link]
from votes v
inner join posts p on p.id = v.postid
where v.votetypeid = 5
and userid <> ##userid:int?5033247## -- who to exclude
and p.body like '%##search##%'  -- what to search fir
group by postid -- we have more then one favorite on some posts
order by count(*) desc -- so the more favorites the higher it is on the list

Don't complain if the results and usability of this solution is sub-par.

Keep in mind SEDE is updated once a week, on Sunday.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .