我目前正面临着连接" NEW"使用concat函数的列名称的关键字..
SET @values =
(SELECT GROUP_CONCAT(CONCAT_WS('.','new', table1.col) SEPARATOR ',')
FROM tbale1, table2, table3, table4
WHERE table3.table3_id = '001'
AND table3.id = table4.table3_id
AND table4.col = table2.col
AND table1.id = table2.table1_id
ORDER BY table2.col);
执行时,不是替换NEW关键字的值(最后插入的记录/值),而是返回NEW.col1,NEW.col2,NEW.col3而不是它们分配的值。请帮我解决这个问题。
所需的输出是SELECT @var =' aa',' bb',' cc'' ccc&#39 ;; 但是当前的输出是SELECT @var = NEW.col1,NEW.col2,NEW.col3,NEW.col4;