+ Reply to Thread
Results 1 to 5 of 5

Formula to show all dates/codes under same Serial Number

  1. #1
    Registered User
    Join Date
    08-22-2016
    Location
    Tennessee, United States
    MS-Off Ver
    MS Office 2010
    Posts
    2

    Formula to show all dates/codes under same Serial Number

    I have basic/intermediate knowledge of excel, but I've pull data together for a project and I want to showcase certain information on a single sheet. So far what I have is 3 sheets, first sheet with initial information, 2nd sheet of data that I wish to pull from and 3rd sheet showing the information I would like to showcase.

    (File Attached) 2nd sheet consists of 6 columns titled: Date, Time, Dispatch, Serial Number, Model, Defect Code (Respectively)

    (File Attached) 3rd sheet shows 7 columns: Dispatch, Date, Serial Number Used, Model, # of Serial Number previous usage, previous date, defect code (respectively, last 2 columns pulling information from 2nd sheet.


    I currently use Vlookup for everything else I need, my issue is vlookup only searches once and the first occurrence.
    I want to be able to search using the Serial Numbers on the 3rd Sheet and searching the entire sheet of the 2nd to pull All the Dates/Defect Codes of each Serial Number Used (respectively).

    I've colored the cells of the information I want to pull into the blank colored cells I want to put them in. I hope the information is clear what I want to do. The black areas on 3rd sheet are intentionally blank/black. 2nd sheet has 685 entries to search through with 419 Unique serial Numbers.

    Thanks for any help. I'm sure this is a very easy fix/formula I'm just overlooking.
    Attached Files Attached Files

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,311

    Re: Formula to show all dates/codes under same Serial Number

    I assume that the black rows are there to allow for the number of responses that you are expecting. However, how are you going to know, in advance, that there are 3 dates for the first one, two for the second, etc...

    It sounds to me like your overcomplicating this considerably!
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  3. #3
    Registered User
    Join Date
    08-22-2016
    Location
    Tennessee, United States
    MS-Off Ver
    MS Office 2010
    Posts
    2

    Re: Formula to show all dates/codes under same Serial Number

    Really isn't overcomplicated at all. I'm just trying to pull information for the columns and showing everything on one sheet.

    Blank areas, as stated, are intentional, but what I didn't state because I assumed it would be understood that it would be for the spaces to show the information I want.

    But a simple Countif for each SN to show how many times it appeared in the 2nd sheet data (Thusly being previously used # of times, forgive me for not including that if it was important)

    All I need is to find a formula to figure out the pull info from 2nd sheet to show each # of previously used. I saw {=small()} but I don't fully understand that formula to use it.

    Vlookup, as mentioned doesn't work for all uses of the SN. This is basically trying to find a trend in things.

  4. #4
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP and 2007
    Posts
    15,888

    Re: Formula to show all dates/codes under same Serial Number

    Would you be willing to use filters rather than formulas? I think that is how I would approach this problem:
    Autofilter: http://www.contextures.com/xlautofilter01.html
    Advanced filter: http://www.contextures.com/xladvfilter01.html
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  5. #5
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,311

    Re: Formula to show all dates/codes under same Serial Number

    Hellper column (can be hidden) 3rd sheet, H", copied down.
    =IF(C2="",H1,C2)

    Array formula F2,

    =INDEX('[2nd sheet ex..xlsx]Sheet1'!$A:$A,SMALL(IF('[2nd sheet ex..xlsx]Sheet1'!$D$2:$D$9=$H2,ROW('[2nd sheet ex..xlsx]Sheet1'!$D$2:$D$9)),COUNTIF($H$2:$H2,$H2)))

    in G2:
    =INDEX('[2nd sheet ex..xlsx]Sheet1'!$F:$F,SMALL(IF('[2nd sheet ex..xlsx]Sheet1'!$D$2:$D$9=$H2,ROW('[2nd sheet ex..xlsx]Sheet1'!$D$2:$D$9)),COUNTIF($H$2:$H2,$H2)))

    Array Formulae are a little different from ordinary formulas in that they MUST be confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER.

    You will know the array is active when you see curly braces { } appear around the outside of your formula. If you do not CTRL+SHIFT+ENTER you will (almost always) get an error message or an incorrect answer. Press F2 on that cell and try again.

    Don't type the curly braces yourself - it won't work...
    Attached Files Attached Files

+ 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] Formula to show number of months (1st and last month inclusive) between 2 dates
    By antmcg12 in forum Excel Formulas & Functions
    Replies: 16
    Last Post: 12-17-2020, 04:46 PM
  2. Serial Number on array formula.
    By Umair.711 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-26-2014, 03:12 PM
  3. [SOLVED] Serial Number Error in Array Formula
    By Scott_88 in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 11-12-2012, 07:04 AM
  4. Replies: 3
    Last Post: 10-11-2012, 02:11 PM
  5. Serial dates in VBA vs Serial dates in Excel
    By tom.hogan in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-20-2011, 09:10 AM
  6. Finding a serial number in a list of serial numbers
    By zocoloco in forum Excel General
    Replies: 2
    Last Post: 02-04-2009, 05:20 AM
  7. How to enter serial no/ codes without duplicates
    By premdasp in forum Excel General
    Replies: 1
    Last Post: 07-14-2008, 06:12 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