title: Optimize SQL query with many left join
body: <p>I have a SQL query with many left joins</p>
  
  <pre><code>SELECT COUNT(DISTINCT po.o_id)
  FROM T_PROPOSAL_INFO po
  LEFT JOIN T_PLAN_TYPE tp ON tp.plan_type_id = po.Plan_Type_Fk
  LEFT JOIN T_PRODUCT_TYPE pt ON pt.PRODUCT_TYPE_ID = po.cust_product_type_fk
  LEFT JOIN T_PROPOSAL_TYPE prt ON prt.PROPTYPE_ID = po.proposal_type_fk
  LEFT JOIN T_BUSINESS_SOURCE bs ON bs.BUSINESS_SOURCE_ID = po.CONT_AGT_BRK_CHANNEL_FK
  LEFT JOIN T_USER ur ON ur.Id = po.user_id_fk
  LEFT JOIN T_ROLES ro ON ur.roleid_fk = ro.Role_Id
  LEFT JOIN T_UNDERWRITING_DECISION und ON und.O_Id = po.decision_id_fk
  LEFT JOIN T_STATUS st ON st.STATUS_ID = po.piv_uw_status_fk
  LEFT OUTER JOIN T_MEMBER_INFO mi ON mi.proposal_info_fk = po.O_ID
  WHERE 1 = 1
       AND po.CUST_APP_NO LIKE '%100010233976%'
       AND 1 = 1
       AND po.IS_STP &lt;&gt; 1
       AND po.PIV_UW_STATUS_FK != 10
  </code></pre>
  
  <p>The performance seems to be not good and I would like to optimize the query.</p>
  
  <p>Any suggestions please?</p>