Short answers with links by domain

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

select
  a.Score, LEN(a.Body) as length,
  CASE WHEN q.closedDate is null
    THEN ''
    ELSE 'Closed'
  END as Closed,
  CASE WHEN q.CommunityOwnedDate is null
    THEN ''
    ELSE 'CW'
  END as CommWiki,
  q.AnswerCount as AnswerCount,
  a.Id as [Post Link],
  a.body
from
  Posts a,
  Posts q
where
  a.PostTypeId = 2
  and a.Score <=  ##AnswerScoreMax:int##
  and a.Score >= ##AnswerScoreMin:int##
  and LEN(a.Body) < ##AnswerLength##
  and UPPER(a.body) like '%<A HREF="HTTP://%'
  and a.ParentId = q.id
  and not exists (
    select 1
    from
      PostHistory ph
    where
      ph.PostId = q.id
      and ph.PostHistoryTypeId = 14
  )
order by length ASC, a.Score ASC

Enter Parameters

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