${if(len(shop) = 0,""," and shop_name_s in('" +replace(shop, ",", "','") + "')") }${if(len(pline) = 0,""," and pline_name_s in('" +replace(pline, ",", "','") + "')") }
使用EXISTS的方式替换看一下。再看一下执行计划吧。in没有走索引了
用这个
${if(len(shop)==0,"","and ("+JOINARRAY(MAPARRAY(shop, "find_in_set('"+item+"',shop_name_s)"),' or ')+")")}
并且把shop的控件返回类型换成“数组”