Which of my answers received more votes than the accepted answer?


Please login or register to vote for this query.

(click on this box to dismiss)

Computational Science Meta

Q&A about the site for scientists using computers to solve scientific problems

WITH Utable AS
Id AS AnswerId,
ParentId AS QuestionId,
Score AS Uscore
FROM Posts  
  OwnerUserId = 7128934  
  AND Posts.PostTypeId = 2
  AND Posts.ParentId IN
    (SELECT Posts.Id FROM Posts WHERE Posts.AcceptedAnswerId IS NOT NULL)
OTable AS
SELECT Score AS Oscore,
ParentId AS Oqid,
Id AS Oaid
FROM Posts
WHERE Posts.ParentId IN (SELECT QuestionId FROM UTable)
AND Posts.Id IN (SELECT DISTINCT AcceptedAnswerId FROM Posts)
Id AS [Post Link],
OTable.OScore AS Accepted_Score,
Utable.Uscore AS MyScore
FROM Posts
  INNER JOIN Utable ON Utable.QuestionId = Posts.Id
  INNER JOIN Otable ON Otable.Oqid = Posts.Id
WHERE AnswerId <> Oaid
  AND Uscore > Oscore

Enter Parameters

Switch sites:
loading Hold tight while we fetch your results