fix relation id getter