Пытаюсь выполнить такую :
INSERT INTO cron_cashback_monthly VALUES(
SELECT m_user.id,m_user.username,sum(pillikan.cb_payment.cb_amount)
AS cashback FROM pillikan.cb_payment cbp
LEFT JOIN m_user mu ON m_user.id=pillikan.cb_payment.user_id
WHERE cb_amount >0
GROUP by m_user.id)
Выходит ошибка :
SQL Error [1064] [42000]: (conn=59) You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'SELECT m_user.id,m_user.username,sum(pillikan.cb_payment.cb_amount)
Спасибо большое, c subquery может ошибка какая?