RegexGroupMatch() is a scalar function that lets you run a regular expression using named groups against a string. It returns the match for the group you've named. RegexGroupMatch() is a SQL CLR function that exposes the System.Text.RegularExpressions' Match() method.
Let's look at a few examples, inspired by a handy Regular Expressions tutorial
declare @regex_pattern varchar(max) = '[_]*([a-z0-9]+(\.|_*)?)+@(?<domain>([a-z][a-z0-9-]+(\.|-*\.))+[a-z]{2,6})'
select dbo.RegexGroupMatch('My email address is [email protected]', @regex_pattern, 'domain')