I have a verify simple query in which I have a variable declared. I would like to create a scalar function that automatically converts whatever I write into the variable, into my finished string:
declare @name varchar(100) = 'firstnameLastname' select @name + '@email.com' My goal is to use this function with a random string which converts it automatically into my Email String. For example:
select udfEmailConversion('RobertSequel') and it should automatically return:
[email protected] How can create a scalar function when I have variables declared in my query?