mysql - Find number of users count in a day who visit the url -


i need query fetch 'number of different users count' in day visit url. structure of table enter image description here

and try query

select distinct `userid`,`url`, from_unixtime(`time`,'%y-%m-%d') date,count(`userid`) usercount `mdl_log` group from_unixtime(`time`,'%y-%m-%d') 

but not work. please me correct query.

use disinct , count together

select count(distinct `userid`) usercount,`url`, from_unixtime(`time`,'%y-%m-%d') date `mdl_log` group from_unixtime(`time`,'%y-%m-%d') 

Comments

Popular posts from this blog

Spring Boot + JPA + Hibernate: Unable to locate persister -

go - Golang: panic: runtime error: invalid memory address or nil pointer dereference using bufio.Scanner -

c - double free or corruption (fasttop) -