The problem here is that you need two queries.
One to count the total number of requests per page regardless of time taken
SELECT cs-uri-stem, COUNT(*) AS all-requests
FROM ex*.log
GROUP BY cs-uri-stem
One to count the number of pages where time-taken > X seconds
SELECT cs-uri-stem, COUNT(*) as total-requests
FROM ex*.log
WHERE time-taken > 1000 <- time_taken is milliseconds
GROUP BY cs-uri-stem
The result you're after would require a JOIN:
SELECT a.cs-uri-stem, COUNT(*) as total-requests, b.all-requests
FROM ex*.log AS a
JOIN (
SELECT cs-uri-stem, COUNT(*) AS all-requests
FROM ex*.log
GROUP BY cs-uri-stem
) AS b ON b.cs-uri-stem = a.cs-uri-stem
WHERE a.time-taken >1000
GROUP BY a.cs-uri-stem
Unfortunately there is no support for JOIN's in LogParser.
What you could do is import the results of both queries into a SQL Database and run the query there:
SELECT a.cs-uri-stem, COUNT(*) as total-requests, b.all-requests
FROM long_running_pages AS a
JOIN all_pages_grouped b ON ( a.cs-uri-stem = b.cs-uri-stem)
GROUP BY a.cs-uri-stem