QUERY PLAN
GroupAggregate (cost=39.59..39.82 rows=6 width=68)
Group Key: (to_date(to_char((bargain_date)::timestamp with time zone, 'yyyy'::text), 'yyyy'::text))
-> Sort (cost=39.59..39.61 rows=6 width=14)
Sort Key: (to_date(to_char((bargain_date)::timestamp with time zone, 'yyyy'::text), 'yyyy'::text))
-> Bitmap Heap Scan on tbl_projects p (cost=4.36..39.52 rows=6 width=14)
Recheck Cond: (client_id = 982)
Filter: (project_status = 3)
-> Bitmap Index Scan on tbl_projects_client_id_idx (cost=0.00..4.36 rows=11 width=0)
Index Cond: (client_id = 982)