+ Reply to Thread
Results 1 to 3 of 3

Num error in formula

Hybrid View

  1. #1
    Registered User
    Join Date
    11-18-2011
    Location
    Ghana, Accra
    MS-Off Ver
    Excel 2007
    Posts
    18

    Num error in formula

    Hello Experts,

    i have a monthly data in sheet one, i am trying to sort by the largest amounts in sheet 2 with a formula, i get a num error with the formula i used, i so realised that when two figures have same figure it repeats the first instance all though i thought the below formula will resolve that. kindly assist to sort the data by the largest amount and deal with the num error. thanks



    INDEX(Sheet1!A$2:A$21,SMALL(IF(Sheet1!$N$2:$N$21=P20,ROW(Sheet1!$A$2:$A$21)-ROW(Sheet1!$A$2)+1,""),COUNTIF(Sheet1!$N$2:N19,Sheet1!N19)))
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,078

    Re: Num error in formula

    Yep, it's cos you have duplicate figures, ie the "-"s where there is no actual figure.
    You're gonna get the same problem if an actual figure is duplicated in the column, though unlikely this is not the best method to sort this.
    A macro solution would be best.

    Anyway this cures the #NUM error

    in Sheet2!C3
    =INDEX(Sheet1!A$2:A$21,MATCH(P3,Sheet1!B$2:B$21,0),1)
    and copy down

    but does of course create a repeat of the first "-" it finds.
    Maybe you can base something from this?
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Registered User
    Join Date
    11-18-2011
    Location
    Ghana, Accra
    MS-Off Ver
    Excel 2007
    Posts
    18

    Re: Num error in formula

    Thanks special K, This problem with this solution is it repeats an item i want to return if the figures are the same, i want to prevent that from happening, could you adjust the formula for me. Pls not a VBA solution

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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