Hi! Looking into grapcool now, a quick general gra...
# prisma-whats-new
s
Hi! Looking into grapcool now, a quick general grapql question:
Copy code
type Player implements Node {
 fotballlPlayer: FotballPlayers
 volleyballPlayer: VolleyballPlayers
  ....
}

type FotballPlayer implements Node {
    player: Player!
    ....Fotball things
}

type VolleyballPlayer implements Node {
    player: Player!
    ..... Volleyball things
}
or can I do something like
Copy code
type FotballPlayer implements Player {
    ....Fotball things
}

type VolleyballPlayer implements Player {
    ..... Volleyball things
}
So VolleyballPlayer and FotballPlayer should have a one to one relations with the player, its basically just additional attributes on the object. But there will be so many overlapping fields name that i did not want to put it all in players and have volleyball_posistion and fotball_posisiton etc. there.
i
That would be interfaces, which aren’t out yet (in GraphCool, that is)
m
Here’s the official spec on interfaces: http://graphql.org/learn/schema/#interfaces
s
Seems like you are duplicating the fields there? I want the fields to be the same, so I can not have the duplicates values e.g FotballPlayer and VolleyballPlayer share the same "base" object. But then I undertand more, the
implement
part is very similar to Java and oher OOP
implement
. Sees like my first approche was the coorect one
Thanks for the help 🙂
i
Not sure I understand what you meant but at least you figured it out 🙂