SELECT TOP 100 q.Id AS [User Link] , LOG( q.QScore ) / L...

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

-- Enter Query Title
-- Enter Query Description

SELECT
     TOP 100
       q.Id AS [User Link]
     , LOG( q.QScore ) / LOG( a.AScore )
     , LOG( q.QScore ) + LOG( a.AScore )
     , q.QScore
     , a.AScore
FROM
    (
SELECT
      p.OwnerUserId AS Id
    , CASE
      WHEN SUM( p.Score ) > 1
      THEN 5 * SUM( p.Score ) 
      ELSE 1.001
      END AS QScore
FROM
    Posts p
WHERE
    p.PostTypeId = 1
AND p.CommunityOwnedDate IS NULL
GROUP BY
    p.OwnerUserId
    ) AS q
    , (
SELECT
      a.OwnerUserId AS Id
    , CASE
      WHEN SUM( a.Score ) > 1
      THEN 10 * SUM( a.Score ) 
      ELSE 1.001
      END AS AScore
FROM
    Posts a
WHERE
    a.PostTypeId = 2
AND a.CommunityOwnedDate IS NULL
GROUP BY
    a.OwnerUserId
    ) AS a
WHERE
    a.Id = q.Id
AND LOG( q.QScore ) / LOG( a.AScore ) > 10
AND LOG( q.QScore ) + LOG( a.AScore ) < 8

ORDER BY
    LOG( q.QScore ) + LOG( a.AScore ) DESC

Enter Parameters

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