Good afternoon guys, I have the following the following table:
Ihavethefollowingselect:
"SELECT DISTINCT 'ip' FROM 'visualizacoes' WHERE MONTH(data) = MONTH(NOW()) AND id_usuario = :id_usuario"
Use the distinct to return only one record per ip, but would like to return a record of ip per news.
EX: If a given ip views post 1, and then view post 2 I want to return both records.
But if it views post 1 twice I want it to return only one record
PS: Ignore the existence of two columns on date.