To je špatný design, ale tady je vaše odpověď:
select f.id, f.follower, s.username, s.pic
from
(
select id, unnest("array") as follower
from followers_arrays
) f
inner join
small_profiles s on f.follower = s.id
To je špatný design, ale tady je vaše odpověď:
select f.id, f.follower, s.username, s.pic
from
(
select id, unnest("array") as follower
from followers_arrays
) f
inner join
small_profiles s on f.follower = s.id