[~FEAT] Faster select statement for the entity_ids