PrepAway - Latest Free Exam Questions & Answers

What three tasks should you perform next?

You plan to create a custom aggregation function named Function1.
You plan to deploy Function1 to SQL Server 2012.
You need to ensure that Function1 can access a web service. The solution must minimize the number of
changes made to the database.
You create a Microsoft .NET Framework class that contains the definition of Function1.
You upload a certificate to SQL Server.
What three tasks should you perform next?
To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the
correct order.
Select and Place:

PrepAway - Latest Free Exam Questions & Answers

Answer:

Explanation:
Box 1: Modify the TRUSTWORTHY property of the database.
Box 2: Execute the CREATE ASSEMBLY statement.
Box 3: Execute the CREATE AGGREGATE statement.
Note:
* TRUSTWORTHY CREATE signature
The TRUSTWORTHY property indicates whether the instance of SQL Server trusts the database and the
contents within it.
* CREATE AGGREGATE
Creates a user-defined aggregate function whose implementation is defined in a class of an assembly in the
.NET Framework. For the Database Engine to bind the aggregate function to its implementation, the .NET
Framework assembly that contains the implementation must first be uploaded into an instance of SQL Server
by using a CREATE ASSEMBLY statement.
* Example:
ALTER DATABASE [DatabaseName] SET TRUSTWORTHY ON
GO
CREATE ASSEMBLY [CLR.Utilities] FROM ‘C:\\Path\\To\\File\\CLR.Utilities.dll’ WITH PERMISSION_SET =
UNSAFE
GO
CREATE AGGREGATE [dbo].[Concatenate] (@input nvarchar(max)) RETURNS nvarchar(max)
EXTERNAL NAME [CLR.Utilities].[CLR.Utilities.Concatenate]
GO

2 Comments on “What three tasks should you perform next?


Leave a Reply