Question
Please use this link to download the database: https://drive.google.com/drive/folders/11FLfdYZUbIDxLuifwLcZfb9sMxGBnPiI Part 2 Multi-Statement Table-Valued UDF Create a multi-statement table-valued UDF in the InsideTSQL2008 database . The
Please use this link to download the database:
https://drive.google.com/drive/folders/11FLfdYZUbIDxLuifwLcZfb9sMxGBnPiI
Part 2 Multi-Statement Table-Valued UDF
Create a multi-statement table-valued UDF in the InsideTSQL2008 database. The function should take a City, NVARCHAR(15), as a parameter and return a list of employees in that city per the HR.Employees table. The result table should have three columns, LastName, FirstName and Title with their datatypes identical to the HR.Employees table. If there are no employees in that city specified by the argument then the LastName column should contain No Employees, and the FirstName should contain the value of the argument and the Title should be null.
Here are the two examples of output:
SELECTFROM dbo. EmpInCity('Kirkland') 100 % Results Messages Last Name First NameTitle 1 Lew Judy Sales Manager SELECTFROM dbo. EmpInCity('Kirkland') 100 % Results Messages Last Name First NameTitle 1 Lew Judy Sales ManagerStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started