Having a little trouble with this question: Using the two tables below, create a subquery or join statement that shows the player, Team, and No in the Player_PROFILE table for all players coached by Fisher.

I came up with the following SQL code but I'm not sure how to finish it or if its even right:
SELECT PLAYER_PROFILE.Player, PLAYER_PROFILE.Team,
PLAYER_PROFILE.No
FROM PLAYER_PROFILE
INNER JOIN PLAYER_DETAIL
ON......
Isnt it this - or am I missing something in your question
SELECT PLAYER_PROFILE.Player, PLAYER_PROFILE.Team, PLAYER_PROFILE.No
FROM PLAYER_PROFILE
INNER JOIN PLAYER_DETAIL ON PLAYER_PROFILE.Player=PLAYER_DETAIL.Player
WHERE PLAYER_DETAIL.Coach = 'Fisher';
SELECT PLAYER_PROFILE.Player, PLAYER_PROFILE.Team,
PLAYER_PROFILE.No
FROM PLAYER_PROFILE
INNER JOIN PLAYER_DETAIL
ON PLAYER_PROFILE.Player = PLAYER_DETAIL.Player
WHERE PLAYER_DETAIL.Coach = "Fisher"
You do the inner join (http://www.w3schools.com/sql/sql_join_inner.asp) on the player name because you need some piece of data that is unique for each player ... normally this would be some sort of ID (number/guid) but in the case of your data, it is the player name.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With