Users closest to Socratic

0

Please login or register to vote for this query.

(click on this box to dismiss)

Motor Vehicle Maintenance and Repair Meta

Q&A about the site for mechanics and DIY enthusiast owners of cars, trucks, and motorcycles

select
  Username as [User Link],
  UserId as [User Id],
  Reputation,
  DayCount % 100 as Percentage,
  Floor(DayCount / 100) as [Badges earned]
from
  (select
    U.Id as Username,
    U.Id as UserId,
    U.Reputation as Reputation,
    (
      select
        Count(distinct Convert(date, P.CreationDate))
      from
        Posts as P
      where
        P.PostTypeId = 1 and
        P.Score > 0 and
        P.ClosedDate is null and
        P.OwnerUserId = U.Id
    ) as DayCount
  from
    Users as U
  ) as Data
where
  DayCount > 0
order by
  DayCount % 100 desc

Enter Parameters

Options:
Switch to main site
loading Hold tight while we fetch your results