+ Reply to Thread
Results 1 to 5 of 5

Former employees strange match formula syntax

  1. #1
    Registered User
    Join Date
    07-19-2018
    Location
    Australia
    MS-Off Ver
    365
    Posts
    4

    Question Former employees strange match formula syntax

    Hi guys,

    I have a very large and cumbersome legacy spreadsheet that doesn't seem to be doing what its supposed to. The creator passed away and I cannot figure out a couple of match formulas that he's got in a larger sum product formula. At this stage I want to understand why he's written these match formulas this way...

    =MATCH('FY20 SALEABLE TOTAL'!$A$10:$A$62,'FY20 UNITS BY DAY'!$E42,0)

    He has an array as the look-up and a single cell as the array . The results of the match when written separately are #NA and what it ends up trying to match out of the array is unpredictable, the formula doesn't even make sense for the rest of the formula if you switch them around either. Just as in case the whole formula can provide a clue it is:

    =IFERROR(SUMPRODUCT(--ISNUMBER(MATCH('FY20 SALEABLE TOTAL'!$A$10:$A$62,'FY20 UNITS BY DAY'!$E42,0)*MATCH('FY20 SALEABLE TOTAL'!$E$7:$BE$7,'FY20 UNITS BY DAY'!F$2,0)),'FY20 SALEABLE TOTAL'!$E$10:$BE$62)*GETPIVOTDATA("sum of KGs",'PACKED %'!$B$1,"TRXDATE",F$4)*GETPIVOTDATA("sum of OM",PRODUCTS!$A$3,"ITEMNMBR",$B42),0)

    Can anybody spot what I am missing?

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: Former employees strange match formula syntax

    Welcome to the forum!

    Out of context, almost impossible to say since you don't tell us what it's supposed to be doing or in what specific way it is failing.

    Will you please attach a sample Excel workbook? We are not able to work with or manipulate a picture of one and nobody wants to have to recreate your data from scratch.

    1. Make sure that your sample data are REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired results are also shown (mock up the results manually).

    3. Make sure that all confidential data is removed or replaced with dummy data first (e.g. names, addresses, E-mails, etc.).

    4. Try to avoid using merged cells as they cause lots of problems.

    Unfortunately the attachment icon doesn't work at the moment, so to attach an Excel file you have to do the following: just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

    Please pay particular attention to point 2 (above): without an idea of your intended outcomes, it is often very difficult to offer appropriate advice.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Expert
    Join Date
    06-08-2012
    Location
    Left the forum!
    MS-Off Ver
    Left the forum!
    Posts
    5,189

    Re: Former employees strange match formula syntax

    =MATCH('FY20 SALEABLE TOTAL'!$A$10:$A$62,'FY20 UNITS BY DAY'!$E42,0) will return an array of 53 matches for the 53 cells in the criteria., by reversing it, =MATCH('FY20 UNITS BY DAY'!$E42,'FY20 SALEABLE TOTAL'!$A$10:$A$62,0) you only get 1 match.

    The way the formula is constructed, the first match looks for all of the rows that meet 1 criteria, rather than just a single match. The second match does the same for the columns. The true matches are then multipled by the values in the range 'FY20 SALEABLE TOTAL'!$E$10:$BE$62 to give the final sumproduct total.

    Finally the sumproduct total is multipled by the getpivot results.

    If the results of the formula are not as expected, the evaluation tool can be your best friend. Select the cell with the formula, then press Alt m v.

  4. #4
    Registered User
    Join Date
    07-19-2018
    Location
    Australia
    MS-Off Ver
    365
    Posts
    4

    Re: Former employees strange match formula syntax

    Thanks jason, I haven't used the Match formula that way before so thanks for the easy to understand answer. I went over it with the Evaluation tool but (as I now understand) It was just displaying a large range of N/As for the 53 matches which was throwing me. I'm quicker at knocking up a bit of vba than writing these long formulas so I normally just do that if a formula is getting too hard.

  5. #5
    Registered User
    Join Date
    07-19-2018
    Location
    Australia
    MS-Off Ver
    365
    Posts
    4

    Re: Former employees strange match formula syntax

    Sorry Ali, I was only trying to understand the Match syntax used to try to understand what the creator was trying to achieve with this particular sheet in the workbook. As the whole thing is commercially sensitive and grabs information from various sources I thought it better to not upload a copy and just get the small piece of info that was holding me up.

    jason.b75 has answered my question nicely and I have used that information to decipher what they were trying to achieve and fixed it.

    Thank you for taking the time to reply and I will definitely try to follow your suggestions on future posts.
    Last edited by j.peel; 04-09-2019 at 04:56 PM. Reason: missing something

+ 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. Replies: 10
    Last Post: 07-27-2017, 12:44 PM
  2. [SOLVED] Formula Syntax with INDEX/MATCH and other table references
    By phpolicylady in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 01-12-2015, 06:18 PM
  3. [SOLVED] Index Match Match - syntax problem
    By Dabooka in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 12-01-2014, 09:05 AM
  4. Use Index(Match(0,If To Get List Of Employees Within Dates For Calendar
    By jcaynes in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-20-2014, 07:25 AM
  5. Forecast How Many Employees To Hire Based on Active and Termed Employees
    By Kanook22 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-12-2014, 01:19 PM
  6. Replies: 2
    Last Post: 03-11-2013, 09:59 PM
  7. Match formula syntax
    By Traymond in forum Excel General
    Replies: 5
    Last Post: 01-11-2011, 01:37 AM

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