Note: this question is part of a series of questions that use the same or similar answer choices. An answer
choice may be correct for more than one question in the series. Each question is independent of the other
questions in the series. Information and details provided in a question apply only to that question.
You are developing an application to track customer sales.
You need to create a database object that meets the following requirements:
– Return a value of 0 if data inserted successfully into the Customers table.
– Return a value of 1 if data is not inserted successfully into the Customers table.
– Support logic that is written by using managed code.
What should you create?
A.
extended procedure
B.
CLR procedure
C.
user-defined procedure
D.
DML trigger
E.
DDL trigger
F.
scalar-valued function
G.
table-valued function
Explanation:
DML triggers is a special type of stored procedure that automatically takes effect when a data manipulation
language (DML) event takes place that affects the table or view defined in the trigger. DML events include
INSERT, UPDATE, or DELETE statements.DML triggers can be used to enforce business rules and data
integrity, query other tables, and include complex Transact-SQL statements.
A CLR trigger is a type of DDL trigger. A CLR Trigger can be either an AFTER or INSTEAD OF trigger. A CLR
trigger canalso be a DDL trigger. Instead of executing a Transact-SQL stored procedure, a CLR trigger
executes one or more methods written in managed code that are members of an assembly created in the .NET
Framework and uploaded in SQL Server.
https://msdn.microsoft.com/en-us/library/ms178110.aspx
Correct.