Improve company productivity with a Business Account.Sign Up
Declare @msg1 varchar(30)
Set @msg1 = 'age 20'
Declare @msg varchar(30)
set @msg = 'region new york'
when CHARINDEX('region',@msg) > 0 then REPLACE (@msg ,'region','')
end as Test,
when CHARINDEX('age',@msg1) > 0 then REPLACE (@msg1 ,'age','')
end as Test1
Open in new window
An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.
One of a set of tools we're offering as a way of saying thank you for being a part of the community.
when CHARINDEX('region',Msg) > 0 then REPLACE (Msg ,'region','')
when CHARINDEX('age',Msg) > 0 then REPLACE (Msg ,'age','')
end as Test
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
Please enter a first name
Please enter a last name
Must be at least 4 characters long.
Join and Comment
From novice to tech pro — start learning today.
Premium members can enroll in this course at no extra cost.