Stored Procedure Programming Concepts - IF THEN | Essential SQL
Stored Procedures Unpacked: https://www.udemy.com/stored-procedures-unpacked-learn-to-code-t-sql-stored-procs/?couponCode=YOUTUBE-VDESC-V1. Access the FULL course and downloadable PSDs/practice code/supplemental materials now.” In this lesson we're going to work with IF/THEN statements. An IF/THEN statement is SQL's program logic switch. If you think about train tracks, when a train is running down the train track and it comes across a switch, it needs to make a choice. It can go down either one track or another. When it comes to programing, the IF/THEN statement is like that switch. When the program is running the code and it comes across an IF/THEN statement, it makes a choice. Depending upon the condition, it's evaluation, it makes a choice. Depending on the choice, it will run either one code block or if there's an else statement, then another code block. The IF/THEN statement is like SQL's programming logic switch. Let's go through some examples to see how this works.