What is the "reciprocity" of the site?

0

Please login or register to vote for this query.

(click on this box to dismiss)

Calculate the percentage of users who have posted both a question and an answer.

Stack Overflow

Q&A for professional and enthusiast programmers

-- What is the "reciprocity" of the site?
-- Calculate the percentage of users who have posted both a question and an answer.
DECLARE @UserCount decimal(19,5)
SELECT @UserCount = COUNT(Users.Id) FROM Users

SELECT COUNT(Users.Id) / @UserCount * 100
FROM Users
WHERE Users.ID IN (SELECT OwnerUserId FROM Posts WHERE Posts.PostTypeId = 1)
AND Users.ID IN (SELECT OwnerUserId FROM Posts WHERE Posts.PostTypeId = 2)

Enter Parameters

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