Questions that might need to be Protected

1

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

/*
    Improved and adapted from:
      http://data.stackexchange.com/scifi/query/522626/questions-that-may-need-protection
*/

DECLARE @Today date
SELECT @Today = GetDate()

SELECT TOP 100
  Answers.ParentId AS [Post Link],
  COUNT(Answers.Id) AS PoorQualityAnswers,
  Questions.CreationDate AS [Asked]
FROM Posts Answers
INNER JOIN Posts Questions ON
  Questions.Id = Answers.ParentId AND  
  Questions.PostTypeId = 1 AND
  DATEDIFF(day, Questions.CreationDate, @Today) BETWEEN 1 AND 100
INNER JOIN Users ON
  Answers.OwnerUserId = Users.Id AND
  Users.Reputation < 10 
WHERE
  Answers.PostTypeId = 2 AND 
  (
    LEN(Answers.Body) < 150 OR
    (Lower(Answers.Body) LIKE '%thank%' OR Lower(Answers.Body) LIKE '%thx%' OR Lower(Answers.Body) LIKE '%also%') OR
    Answers.Score <= 5
  )
GROUP BY Answers.ParentId, Questions.CreationDate
ORDER BY PoorQualityAnswers DESC

Enter Parameters

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