Security is a top concern at Frosty Friday, and we need to make sure that not just anyone can see our customer’s contact info.
Run the following script
create or replace table customer_deets (
id int,
name string,
email string
);
insert into customer_deets values
(1, 'Jeff Jeffy', 'jeff.jeffy121@gmail.com'),
(2, 'Kyle Knight', 'kyleisdabest@hotmail.com'),
(3, 'Spring Hall', 'hall.yay@gmail.com'),
(4, 'Dr Holly Ray', 'drdr@yahoo.com');
Apply a column level masking policy that shows me the following when I query using my role:
And the following when I query using any other role:

Remember, if you want to participate:
I’m a big fan of the recent(ish) addition to the functionality where you can use other fields in the data too
Here’s my solution
It’s good that ChatGPT can now write a regex 🙂
Thanks for the challenge! 🙂