Most Interesting Unanswered Questions

0

Please login or register to vote for this query.

(click on this box to dismiss)

Unanswered questions weighted on a composite score based on Votes, Favorites, Age, and Views

Stack Overflow

Q&A for professional and enthusiast programmers

-- Most Interesting Unanswered Questions
-- Unanswered questions weighted on a composite score based on Votes, Favorites, Age, and Views

DECLARE @Tag varchar(50) = '##Tag##'

SELECT TOP 20
    p.[Id] as [Post Link]
FROM
    [Posts] p
WHERE
    p.[PostTypeId] = 1
  AND
    [ClosedDate] IS NULL
  AND
    CHARINDEX('<' + @Tag + '>', p.[Tags]) > 0
  AND
    NOT EXISTS (SELECT c.[Id] FROM [Posts] c WHERE p.[AcceptedAnswerId] = c.[Id] OR (c.[Score] > 0 AND c.[ParentId] = p.[Id]))
ORDER BY
    p.[Score] + (p.[FavoriteCount] * 3) + (p.[ViewCount] / 10000.0) + (DateDiff(d, p.[CreationDate], getutcdate()) / -90.0) DESC

Enter Parameters

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