select * from visitas where ip = '54.167.213.22' and products_id = '12315' and dia = '2015-07-02'