replace count(*) by sum(motion)
replace count(*) by sum(motion)

famibelle/OccupationSalle,famibelle/OccupationSalle,famibelle/OccupationSalle,bugpics/OccupationSalle,bugpics/OccupationSalle,bugpics/OccupationSalle,famibelle/OccupationSalle,bugpics/OccupationSalle