create group constrait. still need to test it works as expected