 -- 1. Get player and guild info (1 row)
select
  p.id as PlayerID,
  p.name as PlayerName,
  g.id as GuildID,
  g.name as GuildName
from
  player p
  join guild g on p.guild = g.id
where
  p.name = $1;