Class: CRatings
File: /home/c/cj33570/public_html/bitrix/modules/main/classes/mysql/ratings.php
Function: CalcUserRatingForumActivity
Line: 144
MySQL Query Error: INSERT INTO b_rating_component_results (RATING_ID, MODULE_ID, RATING_TYPE, NAME, COMPLEX_NAME, ENTITY_ID, ENTITY_TYPE_ID, CURRENT_VALUE) SELECT '3' as RATING_ID, 'FORUM' as MODULE_ID, 'RATING' as RATING_TYPE, 'ACTIVITY' as NAME, 'USER_FORUM_RATING_ACTIVITY' as COMPLEX_NAME, ENTITY_ID, 'USER' ENTITY_TYPE_ID, SUM(CURRENT_VALUE) CURRENT_VALUE FROM ( SELECT AUTHOR_ID as ENTITY_ID, SUM(IF(TO_DAYS(POST_DATE) > TO_DAYS(NOW())-1, 1, 0))*0.2 + SUM(IF(TO_DAYS(POST_DATE) > TO_DAYS(NOW())-7, 1, 0))*0.1+ COUNT(*)*0.05 as CURRENT_VALUE FROM b_forum_message WHERE POST_DATE > DATE_SUB(NOW(), INTERVAL 30 DAY) GROUP BY AUTHOR_ID UNION ALL SELECT USER_START_ID as ENTITY_ID, SUM(IF(TO_DAYS(START_DATE) > TO_DAYS(NOW())-1, 1, 0))*0.4 + SUM(IF(TO_DAYS(START_DATE) > TO_DAYS(NOW())-7, 1, 0))*0.2 + COUNT(*)*0.1 as CURRENT_VALUE FROM b_forum_topic WHERE START_DATE > DATE_SUB(NOW(), INTERVAL 30 DAY) GROUP BY USER_START_ID ) q WHERE ENTITY_ID > 0 GROUP BY ENTITY_ID[Duplicate entry '2147483647' for key 'PRIMARY']

DB query error.
Please try later.