Q&A for professionals and students of engineering
DECLARE @UserId int = ##UserId## select * from Votes where PostId in (select Id from Posts where OwnerUserId = @UserId);