+ Reply to Thread
Results 1 to 4 of 4

How to compare multiple rows in an IF statement

  1. #1
    Registered User
    Join Date
    11-06-2017
    Location
    Lincoln, Nebraska
    MS-Off Ver
    Office 2016
    Posts
    6

    How to compare multiple rows in an IF statement

    Hello! I'm new here and could use some assistance. I have an excel sheet where I'm trying to write a function to see if a claim is valid or not. Column A is a name, Column B is a date, and Column C is my Formula. A claim is valid if the name is new or if the last 'approved' claim was more than 365 days ago.

    My current formula now if: =IF(A3=A2,IF(B3>B2+365,"Approved","Denied"),"Approved")

    This issue I'm running into is 'Mary' could submit 4 different claims where the 4th claim is more then 365 days past the 1st claim but less than 365 days past the 3rd claim. Because the formula is just looking at the row before it's wrongly denying the claim. How can I get excel to compare multiple lines together.

    Thanks!
    Attached Files Attached Files

  2. #2
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: How to compare multiple rows in an IF statement

    Hi lanmel. Welcome to the forum.

    Try this formula.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Dave

  3. #3
    Registered User
    Join Date
    11-06-2017
    Location
    Lincoln, Nebraska
    MS-Off Ver
    Office 2016
    Posts
    6

    Re: How to compare multiple rows in an IF statement

    Thank you!!! Seriously a life saver.

  4. #4
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: How to compare multiple rows in an IF statement

    You are welcome. Thank you for the feedback. If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Compare rows in multiple sheets
    By jesse030 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-10-2016, 11:44 PM
  2. Replies: 7
    Last Post: 05-05-2015, 09:13 AM
  3. Replies: 2
    Last Post: 12-05-2012, 01:52 PM
  4. [SOLVED] Compare and display multiple rows
    By Ron Coderre in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-06-2005, 04:05 AM
  5. Compare and display multiple rows
    By Greg in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 11:05 PM
  6. Compare and display multiple rows
    By Greg in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 10:05 PM
  7. [SOLVED] Compare and display multiple rows
    By Greg in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-09-2005, 12:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1