filtering id list on state