How to write a Conditional Selection SQL QUERY in Magento2?

$  collection->getSelect()->where($  getMainTableAlias.'.entity_id IN (SELECT catText.entity_id FROM '.$  catalogCategoryEntityTextTable.' as catText where catText.attribute_id="'.$  attributeId.'" AND  FIND_IN_SET("'.$  groupId.'", catText.value) GROUP BY   catText.entity_id)'); 

I have this query. I have to remove the first where clause so as to avoid any filters but the rest will remain same. How can I perform this task?