I have two database tables, Team (ID, NAME, CITY, BOSS, TOTALPLAYER) and
Player (ID, NAME, TEAMID, AGE), the rel
You don't have to store the total in the table -- it can be computed when you do a query, something like:
SELECT teams.*, COUNT(players.id) AS num_players
FROM teams LEFT JOIN players ON teams.id = players.team_id
GROUP BY teams.id;
This will create an additional column "num_players" in the query, which will be a count of the number of players on each team, if any.