Select exact subset from table
Prologue

This is enhancing my answer from your other question:

Enforce uniqueness across multiple rows

pre-19c - easy method

Calculate the hash-value of your list of activities and look it up in the group_activities#lock table.

pre-19c - dark side

Create an OPERATOR that does the comparison between two activity_list_nt values.

I consider this a "not ideal solution" because it is tempting you down the path of building your own Domain Index.

19c+

19c introduces the JSON_EQUAL operator.  This makes list comparison easy.

with group_activities_dml as ( 
    select group_id, json_arrayagg( activity_id ) activity_list_json 
    from groups 
    group by group_id 
) 
select * 
from group_activities_dml 
where json_equal( activity_list_json, '[1,2]' )