Troubleshooting Queries

Practice Labs Module
Time
50 minutes
Difficulty
Intermediate

The "Troubleshooting Queries" module provides you with the instruction and server hardware to develop your hands on skills in the defined topics. This module includes the following exercises: Manage Transactions (Evaluating Row-Based Operations vs. Set Based Operations, Implementing Error Handling).

Join over 3 million cybersecurity professionals advancing their career
Sign up with
or

Already have an account? Sign In »

Overview

Introduction

The Troubleshooting Queries module provides you with the instruction and server hardware to develop your hands on skills in the defined topics. This module includes the following exercises:

  • Manage Transactions
  • Evaluating Row-Based Operations vs. Set Based Operations
  • Implementing Error Handling

Lab time: It will take approximately 30 minutes to complete this lab.

Exercise 1 - Manage Transactions

In this exercise, you will learn the following:

  • Use BEGIN, COMMIT, and ROLLBACK TRANSACTION statements
  • Demonstrate the use of transaction isolation level
  • Demonstrate the use of @@Trancount function

Exercise 2 - Evaluating Row-Based Operations vs. Set Based Operations

In this exercise, you will learn the following:

  • Using a cursor to fetch data row by row
  • Combining multiple DML operations using the Merge statement

Exercise 3 - Implementing Error Handling

In this exercise, you will learn the following using SQL Server 2012:

  • Implementing try/catch and throw exception handling in code
  • Using Begin Tran and Commit Tran for transactional consistency
  • Demonstrating ACID Properties
Learning Partner
Comprehensive Learning

See the full benefits of our immersive learning experience with interactive courses and guided career paths.