+ Reply to Thread
Results 1 to 11 of 11

Creating a list without duplicates or array formula

  1. #1
    Registered User
    Join Date
    03-16-2013
    Location
    bath
    MS-Off Ver
    Excel 2007
    Posts
    23

    Creating a list without duplicates or array formula

    Hi, I need to figure out how to draw the top 5 numbers for each type of element into a list, excluding duplicates, without using array formula?

    Can anyone help please?

    Attachment 310671

  2. #2
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Creating a list without duplicates or array formula

    Hi,

    May I ask why you can't use an array formula?

    In I6 and copy across and down:

    =MAX(INDEX(($E$6:$E$34=I$5)*(1-ISNUMBER(MATCH($F$6:$F$34,I$5:I5,0)))*$F$6:$F$34,,))

    Regards
    Last edited by XOR LX; 04-10-2014 at 05:46 AM.
    Click * below if this answer helped

    Advanced Excel Techniques: http://excelxor.com/

  3. #3
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Creating a list without duplicates or array formula

    Slght improvement:

    =IF(ROWS($1:1)>=SUMPRODUCT(0+(FREQUENCY(($E$6:$E$34=I$5)*$F$6:$F$34,$F$6:$F$34)>0)),"",MAX(INDEX(($E$6:$E$34=I$5)*(1-ISNUMBER(MATCH($F$6:$F$34,I$5:I5,0)))*$F$6:$F$34,,)))

    though this would be far more concise with an array formula!

    Regards

  4. #4
    Registered User
    Join Date
    03-16-2013
    Location
    bath
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Creating a list without duplicates or array formula

    Hi Xor! Thanks for your help, worked perfectly! Been trying to work your formulae out. The reason I dont want to use arrays is because I need to keep updating the data which will feed into lots of other sheets. As I understand it this will mean having to redo the array formula each time?

    I thought id be able to adapt this formula for another spreadsheet i am using but can seem to get it working. Any chance you could take a look at why its coming up with value?

    example2.xlsx

  5. #5
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Creating a list without duplicates or array formula

    Firstly, what you about array formulas is not correct.

    Secondly, why do you have all those gaps in your data? Is this unavoidable? It certainly makes things more complex, so suggest you first clean up your data then re-attach.

    Regards

  6. #6
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Creating a list without duplicates or array formula

    Which version of Excel are you using? Your profile says 2003 but you posted an xlsx file which indicates 2007 or later.

    If you have Excel 2010 you can use AGGREGATE function, e.g. for your original data use this ordinary (non-array) formula in I6 copied across and down

    =AGGREGATE(14,6,($E$6:$E$34=I$5)*($F$6:$F$34<I5)*$F$6:$F$34,1)

    when you run out of values you get zeroes, custom format as 0;; to show those as blanks
    Audere est facere

  7. #7
    Registered User
    Join Date
    03-16-2013
    Location
    bath
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Creating a list without duplicates or array formula

    Hi, I can format the data before I put it in, I didn't release the # were causing problems! Can I create an array formula that doesn't change and still update the data?

    I apologise for not changing that in my propfile I am using excel 2007 so the 2010 solution im afraid wouldnt work for that but thank you.

    I have taken out the # and can do that before dropping in the data, no problem.

    example2.xlsx

  8. #8
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Creating a list without duplicates or array formula

    There were still some # values in the data. If you take those out and delete row 2 of the results table then you can use this regular formula in F3 copied across and down

    =MAX(INDEX(($B$3:$B$3000=F$2)*($C$3:$C$3000<F2)*$C$3:$C$3000,0))

    That one will work in Excel 2007, see attached

    Note: if you want to keep the # values in the data then this "array formula" will give you the same results while ignoring non-numeric data

    =MAX(IF(ISNUMBER($C$3:$C$3000),IF(($B$3:$B$3000=F$2)*($C$3:$C$3000<F2),$C$3:$C$3000)))

    confirmed with CTRL+SHIFT+ENTER
    Attached Files Attached Files
    Last edited by daddylonglegs; 04-10-2014 at 08:29 AM.

  9. #9
    Registered User
    Join Date
    03-16-2013
    Location
    bath
    MS-Off Ver
    Excel 2007
    Posts
    23

    Cool Re: Creating a list without duplicates or array formula

    Works like a charm, Thanks a ton!!

  10. #10
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Creating a list without duplicates or array formula

    Based on your last post in this thread, its apparent that you are satisfied with the solution(s) you've received and have solved your question, but you haven't marked your thread as "SOLVED". I will do it for you this time.

    In future, to mark your thread as Solved, you can do the following -
    Select Thread Tools-> Mark thread as Solved.

    Incase your issue is not solved, you can undo it as follows -
    Select Thread Tools-> Mark thread as Unsolved.

    Also, since you are relatively new to the forum, i would like to inform you that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post which helped you. This adds to the reputation of the person who has taken the time to help you.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

  11. #11
    Registered User
    Join Date
    03-16-2013
    Location
    bath
    MS-Off Ver
    Excel 2007
    Posts
    23

    Re: Creating a list without duplicates or array formula

    **Deleted**
    Attached Files Attached Files
    Last edited by darq; 04-15-2014 at 07:26 PM.

+ 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. [SOLVED] Creating a list without duplicates from data on another sheet
    By Losguapos1 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 10-09-2013, 11:44 AM
  2. [SOLVED] creating a second list without duplicates
    By jdeleon in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 08-16-2013, 03:56 PM
  3. [SOLVED] Creating a unique list from a list of duplicates
    By ssu in forum Excel Programming / VBA / Macros
    Replies: 38
    Last Post: 04-29-2013, 08:19 AM
  4. Replies: 2
    Last Post: 08-28-2012, 10:41 PM
  5. Creating a list and removing duplicates
    By JohnGuts in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-17-2007, 12:55 PM

Tags for this Thread

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