QUERY PLAN
Sort (cost=24.51..24.52 rows=2 width=682)
Sort Key: tbl_users.pinyin1 NULLS FIRST, tbl_users.namecut1 NULLS FIRST, tbl_users.pinyin2 NULLS FIRST, tbl_users.namecut2 NULLS FIRST, tbl_users.pinyin3 NULLS FIRST, tbl_users.namecut3 NULLS FIRST, tbl_users.pinyin4 NULLS FIRST, tbl_users.namecut4 NULLS FIRST
-> Hash Join (cost=21.77..24.50 rows=2 width=682)
Hash Cond: (tbl_documents.created_by = tbl_users.id)
-> HashAggregate (cost=11.50..12.70 rows=120 width=4)
Group Key: tbl_documents.created_by
-> Seq Scan on tbl_documents (cost=0.00..11.20 rows=120 width=4)
-> Hash (cost=10.25..10.25 rows=2 width=678)
-> Seq Scan on tbl_users (cost=0.00..10.25 rows=2 width=678)
Filter: (user_status = ANY ('{1,2}'::type_global_user_status[]))