This past week I was given an SQL lab involving functions. My knowledge of SQL pre-dating this lab was minimal at best and am having a hard time getting my head around a particular function.
Four tables:

I am to create a stored function called teamsize which returns the number of players in a given teams name for a particular year. The team name is to be supplied as a parameter passed to the function. To my knowledge a join is required but that is about all I know.
What have I tried:

Any help is appreciated
You need to give it a try.
Your main table would be Team, so you have to
Since you don’t need details about the players, just amount, you can just join the Team1 table with playerTeam1 and count the number of records with a count function.
If you needed the player’s details, you would need to join the other tables, but since it isn’t necessary you are fine with the only 2 tables I mentioned.