#分组查询
SELECT score,GROUP_CONCAT(name) as name FROM esg_test GROUP BY score ORDER BY score desc
#循环测试
DELIMITER ;
CREATE PROCEDURE test_insert()
BEGIN
DECLARE y int(10) DEFAULT 1;
WHILE y<1000
DO
INSERT INTO esg_test(name,score) VALUES ("a"+y,FLOOR(1 + (RAND() * 1)));
SET y=y+1;
END WHILE ;
commit;
END;
CALL test_insert();