Download the featured file here: https://www.bluepecantraining.com/wp-content/uploads/2023/05/Subtract-IF.xlsx
In this Microsoft Excel video tutorial I demonstrate how to subtract based on a given condition or conditions.
In the first example, I only want to subtract time worked if the time in and the time out columns contain times. I also want to subtract 30 minutes for lunch if there is a 'Y' in the 'Lunch?' column. To apply these criteria I use a nested IF and the AND function.
In the second example, I want to match a product category letter with the product's discount. The discount amount is stored in a separate table. I can use a VLOOKUP or XLOOKUP to lookup the discount amount and then perform the subtraction.
00:00 Introduction
00:16 Example one using IF
02:49 Example 2 using VLOOKUP