我有这个表格:
table1
+------+----------+-----------+----------+
| id | org1 | org2 | org3 |
+------+----------+-----------+----------+
| 1 | HR | (NULL) | Staff |
+------+----------+-----------+----------+
| 2 | (NULL) | IT | Dev |
+------+----------+-----------+----------+
| 3 | (NULL) | (NULL) | Finance |
+------+----------+-----------+----------+
我想把所有的值都向左移动,这样最终的结果就是:
table1
+------+----------+-----------+----------+
| id | org1 | org2 | org3 |
+------+----------+-----------+----------+
| 1 | HR | Staff | (NULL) |
+------+----------+-----------+----------+
| 2 | IT | Dev | (NULL) |
+------+----------+-----------+----------+
| 3 | Finance | (NULL) | (NULL) |
+------+----------+-----------+----------+
有没有更优雅的方法来做到这一点?