QUERY PLAN
Limit (cost=205.52..206.09 rows=10 width=380)
-> Unique (cost=205.52..238.81 rows=579 width=380)
-> Sort (cost=205.52..206.97 rows=579 width=380)
Sort Key: s.updated_at DESC, s.id, s.name, s.abbr, s.pinyin_shortcut, s.main_products, s.company_nature, s.website, s.established_at, s.capital, s.corp_rep, s.reg_address, s.telephone, s.fax, s.description, s.main_contact, s.created_by, s.created_at, s.working_address, s.capital_currency, s.payment_cycle, s.account_number
-> HashAggregate (cost=173.16..178.95 rows=579 width=380)
Group Key: s.id
-> Hash Right Join (cost=34.03..169.93 rows=1294 width=380)
Hash Cond: (c.supplier_id = s.id)
-> Seq Scan on tbl_contacts c (cost=0.00..132.49 rows=1294 width=4)
Filter: (supplier_id IS NOT NULL)
-> Hash (cost=26.79..26.79 rows=579 width=380)
-> Seq Scan on tbl_suppliers s (cost=0.00..26.79 rows=579 width=380)