Forum Discussion

UserBlue1973's avatar
UserBlue1973
Copper Contributor
May 19, 2020

Check if parent row has corresponding values

I have a table in an Excel 2016 spreadsheet that has hierarchical rows:

 

 

(Here's an Excel-friendly version that can be copied/pasted into a spreadsheet.)

IDPARENTUseWith1UseWith2UseWith3UseWith-CheckParent
10 WORKORDERSR  
2010SR   
3010WORKORDERJOBPLAN  
4010WORKORDER   
5040WORKORDERJOBPLANTOOLITEM 

 

Question:

 

In column F, I want to flag child rows where the values in C, D, or E are missing from the parent row.

 

Example:

 

Is there a way to do this in Excel 2016?

5 Replies

    • UserBlue1973's avatar
      UserBlue1973
      Copper Contributor

      bhushan_z Thanks, however, I can't download the .xlsm file due to security reasons.

      Is there a reason why the file needs to be a .xlsm?

      • bhushan_z's avatar
        bhushan_z
        Iron Contributor

        UserBlue1973 : even i m not sure it was saved as .xlsm, hahaha

        here is new file in .xlsx 

        Also refer below formula just for your reference.

        =IF(B2="","",IF(AND(D2="",E2=""),"",IF(D2="","ERROR["&E2&" is missing from parent #"&B2&"]",IF(E2="","ERROR["&D2&" is missing from parent #"&B2&"]","ERROR["&D2&" and "&E2&" is missing from parent #"&B2&"]"))))

Resources