0

Please login or register to vote for this query.

(click on this box to dismiss)

Show users who marked my posts as "favorites", and which posts they marked...

Stack Overflow

Q&A for professional and enthusiast programmers

-- Who Favorited Me?
-- Show users who marked my posts as "favorites", and which posts they marked...

DECLARE @UserId int = ##UserId##

select 
  votes.userid as [User Link], 
  posts.id as [Post Link], 
  votes.votetypeid 
 from votes 
 join posts 
   on posts.id = votes.postid 
   
 where 1 = 1
   and posts.owneruserid=@UserID 
   --and votes.postid = 23748285 
   and votetypeid = 3
   
 order by votes.votetypeid desc

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results