INSERT INTO cscart_product_popularity (
`viewed`, `added`, `deleted`, `bought`,
`total`, `product_id`
)
VALUES
(1, 0, 0, 0, 3, 514) ON DUPLICATE KEY
UPDATE
viewed = viewed + 1,
added = added + 0,
deleted = deleted + 0,
bought = bought + 0,
total = total + 3