'JPQL JPA query from a @jointable

public class TeamSeason implements Serializable{
    @ManyToMany(fetch = FetchType.LAZY)
    @JoinTable(name = "teamseasonplayer", 
       joinColumns={
         @JoinColumn(name="teamId", insertable = false, updatable = false), 
         @JoinColumn(name="year",  insertable = false, updatable = false)}, 
       inverseJoinColumns={
         @JoinColumn(name="playerId", insertable = false, updatable = false)})
    Set<Player> seasonplayers = new HashSet<Player>();
}

Above is a sample code of a join table I was wondering if it was possible to query from this because I need this table to retreive the names and gamesplayed from the "Player" table



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source