Brief Summary
This T-SQL course teaches you how to combine datasets, create procedures, and handle errors. You'll learn essential commands like MERGE, UNION, and how to apply conditional logic. No fancy prerequisites, just dive in with a hint of Excel or Access experience!
Key Points
-
Merge datasets using MERGE statement
-
Add error handling with TRY, CATCH, and THROW
-
Use UNION, UNION ALL, INTERSECT, and EXCEPT for dataset comparison
-
Create procedures for executing parameterized commands
-
Understand and apply CASE, ISNULL, and COALESCE for conditional logic
Learning Outcomes
-
Write effective procedures for database operations
-
Implement error handling in T-SQL code
-
Combine and compare datasets using UNION and INTERSECT
-
Utilize CASE, ISNULL, and COALESCE for data manipulation
-
Execute MERGE to manage conflicts in table data
About This Course
Using TSQL, merge datasets together, create procedures & incorporate error handling. SQL Server 2012-2022, inc. 2019
This course is the foundation for the Microsoft Certificate 70-461: "Querying Microsoft SQL Server 2012/2014". Please note - this certificate is no longer being offered by Microsoft. However, the exam requirements allow you to have a good understanding of T-SQL.
Welcome to Session 4 of this T-SQLÂ course. In this course:
We will further encapsulate our routines by creating procedures, allowing us to EXECUTE parameterised commands with just one statement.
We'll add some error handling with TRY, CATCH and THROW.
We'll also combine datasets together and compare them, by looking at
UNION and UNION ALL, which allows us to combine sets,
INTERSECT and EXCEPT, which compares datasets, and
the mighty MERGE statement, which allows for conditional INSERT, UPDATE and DELETEs.
We'll also create conditional logic:
CASE, the equivalent of the IF statement in Excel,
ISNULL and Coalesce, which replaces NULLs,
No prior knowledge other than what we covered in Sessions 1 to 3 is required. However, prior experience with Excel or Access would be beneficial.
There are regular quizzes to help you remember the information.
Once finished, you will know what how to write procedures, add error handling, and combine datasets together and compare them, and we'll have expanded on our current knowledge of T-SQL.
Combine and compare datasets using UNION, UNION ALL, INTERSECT and EXCEPT
Understand the difference between and use of CASE, ISNULL and COALESCE
MERGE two tables together, taking different actions if similar rows exist in both tables than if they don't.
Gisela M. B. A.
Thnks for your knowledge, I learned a lot.