Hi, @Tanya Sharma
You are welcome.
You can have a try of this function: =IF(VLOOKUP(A1,"Data range",17,FALSE)="First data need to compare", "SAME', "DIFFERENT")
If you have any updates, please feel free to share with us.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in email-notifications to enable e-mail notifications if you want to receive the related email notification for this thread.