+ Reply to Thread
Results 1 to 8 of 8

Skip "0" values and find the next one.

  1. #1
    Registered User
    Join Date
    01-24-2021
    Location
    United States
    MS-Off Ver
    Office 365 Pro Plus
    Posts
    7

    Question Skip "0" values and find the next one.

    Good evening everyone!

    Firstly, attached is my sample excel spreadsheet (heavily cutdown).

    The SQL Database can show many steps that run through the facility.

    The "Name" (in column G) can show up many times within that DB (for the multiple steps) and sometimes a step will be registered at step "0".

    I would like column O "Current Fab step" or W "Current TDI step" to return the next value of it comes across a "0" from the "Raw data" sheet. I am currently using a VLOOKUP().

    Thank you!
    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 2403
    Posts
    44,036

    Re: Skip "0" values and find the next one.

    I do not understand what you want when you say:

    I would like column O "Current Fab step" or W "Current TDI step" to return the next value of it comes across a "0"

    from the "Raw data" sheet.

    Please explain, with examples, wexactly what you mean. One guess, though. I shall assume you mean the largest value from column E (Step Number) matching the SKY or PSD number. In which case (W12, copied down):

    =IFERROR(AGGREGATE(14,6,vwADFab_LotScans[StepNumber]/(vwADFab_LotScans[LotID]=S12),1),"")
    Attached Files Attached Files
    Last edited by Glenn Kennedy; 01-26-2021 at 03:55 AM.
    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.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Registered User
    Join Date
    01-24-2021
    Location
    United States
    MS-Off Ver
    Office 365 Pro Plus
    Posts
    7

    Re: Skip "0" values and find the next one.

    Apologies for the lack of details and the typo.

    Currently, columns O and W pull data from sheet "Raw data" using a VLOOKUP function to look for the most recent step number that the "NAME" processed through. Unfortunately, the MAX value won't work because some processes require a step that make it jump up to 1000+ for a few days.

    I currently have the query setup up so the '!Raw Data!B' is sorted from newest to oldest. Giving the most recent information at the top (most recent step number).

    I would like my VLOOKUP function to "find the next row" if the current one has a step "0" in it thus giving me the next most recent step.

    For example:

    If I look up PDS002879E in "Raw Data A:E" the first instance that shows up is row 49 with a "Step number" of "0".

    It also shows up in row 136 with a "Step number" of "13"


    I would like my VLOOKUP to skip row 49 and give me the value from row 136.

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

    Re: Skip "0" values and find the next one.

    OK.

    =IFERROR(INDEX('Raw data'!E:E,AGGREGATE(15,6,ROW(vwADFab_LotScans[StepNumber])/((vwADFab_LotScans[LotID]=S12)*(vwADFab_LotScans[StepNumber]>0)),1)),"")

    If you look at the sheet, it returns the 13, even though there is a 20 (typed in by me) a bit further down. So, it returns the first non-zero amount, not the largest.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    01-24-2021
    Location
    United States
    MS-Off Ver
    Office 365 Pro Plus
    Posts
    7

    Re: Skip "0" values and find the next one.

    Thank you VERY MUCH!

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

    Re: Skip "0" values and find the next one.

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

    Finally, if that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

  7. #7
    Registered User
    Join Date
    01-24-2021
    Location
    United States
    MS-Off Ver
    Office 365 Pro Plus
    Posts
    7

    Re: Skip "0" values and find the next one.

    Will do. I am very new to this site.

  8. #8
    Registered User
    Join Date
    01-24-2021
    Location
    United States
    MS-Off Ver
    Office 365 Pro Plus
    Posts
    7

    Re: Skip "0" values and find the next one.

    I wanted to ask, for my own knowledge. What does the argument in ROW() doing?

    Thanks

+ 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: 11
    Last Post: 06-05-2020, 02:08 AM
  2. [SOLVED] Brief formula to convert time values to "shift1", "shift2", "shift3".
    By darekpawel in forum Excel Formulas & Functions
    Replies: 20
    Last Post: 04-11-2019, 07:05 AM
  3. Replies: 2
    Last Post: 07-24-2017, 02:19 AM
  4. Replies: 3
    Last Post: 04-14-2013, 11:53 PM
  5. Replies: 0
    Last Post: 01-09-2013, 06:52 PM
  6. Replies: 3
    Last Post: 02-16-2011, 02:55 PM
  7. Replies: 5
    Last Post: 06-26-2006, 09:23 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