williamXinCC opened a new issue, #18973:
URL: https://github.com/apache/shardingsphere/issues/18973

    SELECT person_id,
           open_id
           FROM sf_person
           WHERE tenant_id = #{tenantId} and person_id IN
           (SELECT person_id
           FROM sf_person_unit
           WHERE tenant_id = #{tenantId} and
           unit_id IN
           (SELECT unit_id
           FROM sf_unit
           <where>
               <if test="buildingList != null and buildingList.size() > 0">
                   and building_id IN
                   <foreach collection="buildingList" item="item" index="index" 
open="(" close=")" separator=",">
                       #{item}
                   </foreach>
               </if>
               and tenant_id = #{tenantId}
           </where>
           )and type !=4 and status = 1 and exclusive_state =1
           )


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: 
[email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to