mysql row to column (use of case when)

existing

table1 is as follows

table2 is as follows

 

Need statistics: the sum of the performance of each department for each month

The implementation is as follows:

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324598467&siteId=291194637