In my application, organizations can configure custom user groups. There are also a few system-level user groups (e.g. Admin) every organization has by default. These are distinguished from custom groups by the fact that user_group.orgId = null rather than pointing to a specific organization.
I currently have a unique index on (user_group.orgId, user_group.name) to prevent users from creating two groups with the same name. But I also want to prevent them from naming their groups the same as a system group. Is this possible in MySQL? I believe we're using 5.7.