QUERY PLAN
Limit (cost=42.93..42.94 rows=1 width=155)
-> Group (cost=42.93..42.94 rows=1 width=155)
Group Key: sci.id
-> Sort (cost=42.93..42.94 rows=1 width=155)
Sort Key: sci.id
-> Seq Scan on tbl_sales_contract_invoices sci (cost=0.00..42.92 rows=1 width=155)
Filter: ((cover_invoice_id IS NULL) AND (contract_id = 195))