Here are the SQLs related to this tutorial.
Video tutorial -
Create SQL
CREATE TABLE [dbo].[Emp](
[EmployeeID] [smallint] NOT NULL,
[Email] [nvarchar](50) NOT NULL
)
Insert SQL
INSERT INTO dbo.Emp(EmployeeID,Email) VALUES (1,'adam@demo.com');
INSERT INTO dbo.Emp(EmployeeID,Email) VALUES (2,'mike@demo.com');
INSERT INTO dbo.Emp(EmployeeID,Email) VALUES (3,'mila@demo.com');
INSERT INTO dbo.Emp(EmployeeID,Email) VALUES (4,'david@demo.com');
INSERT INTO dbo.Emp(EmployeeID,Email) VALUES (5,'tina@demo.com');
SQL Query
Update dbo.emp
Set Email = REPLACE(Email, 'demo.com', 'demo1.com')