\c irc-logger
select
	trim(both '_`0123456789' from nick) as label,
	count(*) as messages_valueType_number,
	min(time) as first,
	max(time) as last
from log
group by trim(both '_`0123456789' from nick)
;
