Question 4

0

Please login or register to vote for this query.

(click on this box to dismiss)

Software Engineering

Q&A for professionals, academics, and students working within the systems development life cycle

SELECT
    COUNT(*) AS TotalPosts,
    SUM(CASE WHEN CommentCount = 0 THEN 1 ELSE 0 END) AS PostsWithoutComments,
    FORMAT(CAST(SUM(CASE WHEN CommentCount = 0 THEN 1 ELSE 0 END) AS DECIMAL) * 100 / COUNT(*), 'N2') + '%' AS PercentageWithoutComments
FROM Posts;

Enter Parameters

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