The no-event branch selects event_name, data_key and data_type alongside
count(*) without a GROUP BY, which throws on PostgreSQL (42803) and on MySQL
with ONLY_FULL_GROUP_BY. The event-filtered branch and both ClickHouse
branches already group correctly. Fixes#4359.