table1.total + table2.point =怎么样?

时间:2018-03-03 13:22:16

标签: php mysql

enter image description here

" SELECT * FROM球员INNER JOIN" 。 $ v [" name"]。 " ON players.team_id =" 。 $ v [" name"]。 " .team_id&#34 ;;

抱歉英语不好

我想+两张桌子?

1 个答案:

答案 0 :(得分:0)

您可以将数据存储在单个表格中,然后像这样获取namesscore/whatever_it_is

SELECT name, score FROM players UNION SELECT "Total" AS name, SUM(score) FROM players