Count the number of Users

0

Please login or register to vote for this query.

(click on this box to dismiss)

TeX Meta

Q&A about the site for users of TeX, LaTeX, ConTeXt, and related typesetting systems

SELECT 
    Users.ID,
    CAST(Users.CreationDate AS DATE) AS UserCreateDate,
    MIN(Posts.CreationDate) AS JanuaryFirstPostDate,
    MAX(Posts.CreationDate) AS JanuaryLastPostDate,
    COUNT(Posts.ID)
FROM 
    Users
JOIN 
    Posts ON Users.ID = Posts.OwnerUserId
WHERE 
    Users.CreationDate >= '2021-12-23' AND Users.CreationDate < '2021-12-24'
    AND Posts.CreationDate BETWEEN '2022-01-01' AND '2022-01-31'
GROUP BY
    Users.ID, CAST(Users.CreationDate AS DATE)
ORDER BY
    COUNT(Posts.ID) DESC;

Enter Parameters

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