can't adapt type 'BackrefAccessor'
StackOverflow for questions.

You need to properly join on your relation and then array-agg over the result column you are trying to aggregate...
Hi, I'm trying to use `fn.array_agg` on a backref foreign key. However when trying to loop over the returned, model, I get the following error message:

```
Exception has occurred: ProgrammingError
can't adapt type 'BackrefAccessor'
```

My code looks something like that:

```python
    sources = target.sources.select(
        Sources.name,
        Sources.maintainer,
        fn.array_agg(Sources.results).alias("results"),
    ).group_by(Sources.name, Sources.maintainer)
```

Is it possible to *convert* the BackrefAccessor first to a dict or tuple to get this working? Or is there are different approach?