Tweak trivial_subqueryscan() to consider a SubqueryScan's targetlist
trivial if it contains either Vars referencing the corresponding subplan columns, or Consts equaling the corresponding subplan columns. This lets the planner eliminate the SubqueryScan in some cases generated by generate_setop_tlist().
Showing
想要评论请 注册 或 登录