The power of "what if" has been debated, discussed, deployed, and dreamed about for centuries. It's woven into the fabric of human nature and technology is a product of its power.
Does the IF function have a lot of power in Power BI? Sure. But where does the power of IF have more power than in the house or in the classroom.
Mr. Peterson, IF I do the extra credit this weekend how much will my grade go up?
Mr. Peterson, IF I don’t have any more missing homework assignments for the rest of the quarter will my grade improve?
Mr. Peterson, IF we learn all this Algebra you are teaching how will it help me in the real world?
"Dad, IF I don’t miss any more chores this week can I pick where we go out to eat tonight?”
My response, "IF you don’t miss any more chores, THEN you get to pick where we eat Saturday, ELSE mom and I get to pick where we eat."
You see, IF statements not only get the brain exploring endless possibilities, but they generate a logical flow of thinking throughout a scenario.
That’s exactly how the IF statement works in Power BI. Well, that seems easy, right? But what IF (see what I did there 😉) there are more than just two outcomes? What IF (I did it again 😉) there is a tiered level of response to Jack missing chores? If he doesn’t miss any, then he gets to pick where we eat, but if he misses 1 or 2 then we flip a coin between his choice and Mollie and my choice, but if he misses over 3 then we get the pick of the restaurant. This is where nested IF statements will come into play.
The demos I have set up for this explanation of IF statements will revolve around a real-world classroom scenario that I experienced while teaching and another scenario that I see coming up concerning children’s screen time down the road. Check my demo out below.
If you want or need to increase your Power BI skills, Pragmatic Works On-Demand Learning platform is the perfect place to do it. Our 18 Power BI courses will turn you into a Power BI expert by providing in-depth instruction on all of the capabilities that Power BI provides. Click the link below to get started with a FREE trial!