+ Reply to Thread
Results 1 to 7 of 7

Unique Count

  1. #1
    Registered User
    Join Date
    08-26-2011
    Location
    uk
    MS-Off Ver
    Excel 2003
    Posts
    10

    Unique Count

    Hi everyone ,
    Newbie here , it looks a great resource this site ,, wonder if anyone can help me

    we have a set of data in 2 columns column A and column B , we would like be able to do a unique count of column B in relation to column A, with the output showing unique items in column A`s and a count of Unique items in Column B


    example below ; the output would be A 1 ( as there is only 1 unique item Red) , B 2 ( there are 2 unique items ) , C 3 ( 3 unique items Yellow white and black )

    i know it can be done with pivot table but we wish to just copy the data daily to a spreadsheet and have the output columns calculate automatically .. any help is greatly greatly recieved thanks in advance

    Column A Column B
    A Red
    A Red
    B Green
    B Lime
    C Yellow
    C Yellow
    C white
    C Black

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Unique Count

    2 ways in the attached using a udf or a formula.

    The formula needs to be entered without the {} and confirmed with Ctrl+Shift+Enter as it's an array formula.

    I keep the udf in my personal.xls and use that as it's less hassle to set up.

    Dom
    Attached Files Attached Files
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Unique Count

    I had this cobbled together for the other post.
    It avoids using an array, but needs extra helper columns to remove duplicates from A&B.
    Attached Files Attached Files
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  4. #4
    Registered User
    Join Date
    08-26-2011
    Location
    uk
    MS-Off Ver
    Excel 2003
    Posts
    10

    Re: Unique Count

    Thanks everyone for the information, i think i might have confused things attached is an example of the real data , the principle is the same , column A and Column B are pasted in every day , what i am looking for is column I to show the unique items in Column A , ie only 1 of each MRP controller listed , ie 1 of A15, 1 of C10 etc , this list does vary slightly every day , and then for column J to show the unique count of column B related to column A ( or column I ) ... apprecaite a little more help ... thanks in advance
    Attached Files Attached Files

  5. #5
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: Unique Count

    Hi,

    You can create your unique list using advanced filter and then use the udf or formula I gave in the example file.

    Dom

  6. #6
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Unique Count

    Your Data is a mixture of text and numbers, so I have added another helper to cope with this.
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    08-26-2011
    Location
    uk
    MS-Off Ver
    Excel 2003
    Posts
    10

    Re: Unique Count

    thanks to you both , now working a treat apprecaite the help

+ 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