READ Free Dumps For Microsoft- 70-461
Question ID 15066 | You use Microsoft SQL Server 2012 to create a stored procedure as shown in the following
code segment. (Line numbers are included for reference only.)
The procedure can be called within other transactions.
You need to ensure that when the DELETE statement from the
HumanResourcesJobCandidate table succeeds, the modification is retained even if the
insert into the Audit.Log table fails.
Which code segment should you add to line 14?
|
Option A | IF @@TRANCOUNT = 0
|
Option B | IF (XACT_STATE ( ) ) = 0
|
Option C | IF (XACT_STATE ( ) ) = 1
|
Option D | IF @@TRANCOUNT = l
|
Correct Answer | C |
Explanation Reference: http://msdn.microsoft.com/en-us/library/ms189797.aspx Reference: http://msdn.microsoft.com/en-us/library/ms187967.aspx
Explanation