QUERY PLAN
Limit (cost=28.51..28.53 rows=10 width=78)
-> Sort (cost=28.51..28.57 rows=23 width=78)
Sort Key: created_at DESC
-> HashAggregate (cost=27.78..28.01 rows=23 width=78)
Group Key: id
-> Seq Scan on tbl_client_documents cd (cost=0.00..27.73 rows=23 width=78)
Filter: (client_id = 518)