+ Reply to Thread
Results 1 to 15 of 15

nested formula?

  1. #1
    Registered User
    Join Date
    03-07-2017
    Location
    Ontario
    MS-Off Ver
    2010
    Posts
    21

    nested formula?

    Hi;

    I am trying to create a formula that will combine two separate criteria from one sheet and apply the value from a certain cell. I have attached a file to help better understand.
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: nested formula?

    Put your data on Sheet2 so we know which rows/columns to extract from and re-post the file.

  3. #3
    Registered User
    Join Date
    11-09-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: nested formula?

    I have re posted the attachement as requested. Thank you
    Attached Files Attached Files

  4. #4
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: nested formula?

    Query: "Cash from Sale" Count or Collected?

    And no other data to be extracted?

  5. #5
    Registered User
    Join Date
    11-09-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: nested formula?

    Each of the headings on sheet 1 has data to be extracted from sheet 2 (exact column name) if it matches the cashiers name from sheet1 (Adelle) There are many cashiers so I am hoping to simply copy the formula down. Formulas need to be on sheet 1.

    Hope that is not too confusing.

  6. #6
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,466

    Re: nested formula?

    I guess there are more than 1 name, right? How others be arranged in sheet 2?
    Quang PT

  7. #7
    Registered User
    Join Date
    11-09-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: nested formula?

    I have reposted the attachement again. On sheet 3 you will see how the additional cashiers show on the report. On sheet one I have used Alina to show I would like the data to appear.
    Attached Files Attached Files

  8. #8
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: nested formula?

    ..but for each heading there are 2 values listed under "Count" and "Collected"


    See if attached does what is required.

    I changed the format of Sheet2 to make it much easier to produce/copy down formula.
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    11-09-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: nested formula?

    Actually looking for Collected amounts only. There are many cashiers and the report is exported on a csv file so I would rather not have to transpose the data. I did attach another copy with a sheet 3 to show how it appear for multiple cashier.
    Attached Files Attached Files

  10. #10
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: nested formula?

    In C3 of Sheet3

    =INDEX(OFFSET(Sheet3!$A$1,MATCH($A3,Sheet3!$A:$A,0)+MATCH(C$2,Sheet3!$B:$B,0)-3,3,1,1),0)

    Copy across and down.
    Attached Files Attached Files

  11. #11
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,466

    Re: nested formula?

    Try in C3 sheet1 then drag down and accross:

    Please Login or Register  to view this content.

  12. #12
    Registered User
    Join Date
    11-09-2012
    Location
    London
    MS-Off Ver
    Excel 2007
    Posts
    17

    Re: nested formula?

    It works for the first couple of rows but then starts to repeat figures when I get to the bottom. Can't figure out what it is referencing. I will keep trying. I have about 25 rows on names.

  13. #13
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: nested formula?

    I added 4 more names and it appears to work OK.

    Are all formats (entries) identical i.e. same number of rows?
    Attached Files Attached Files

  14. #14
    Registered User
    Join Date
    03-07-2017
    Location
    Ontario
    MS-Off Ver
    2010
    Posts
    21

    Re: nested formula?

    It appears that those employees that have some of the payment methods missing throw a wrench into the overall formula. I have added an iferror to the beginning of the formulas string as not all employees work everyday. I have highlighted the incorrect info in red.
    Attached Files Attached Files

  15. #15
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,206

    Re: nested formula?

    The only solution I can offer is with "helper" columns in column H, I and J plus a "lookup" table in L & M

    in H2

    =IF(B2="","",IFERROR(VLOOKUP($B2,$L$1:$M$18,2,0),""))

    in I2

    =J2&H2

    in J2

    =IF(COUNTIF($A$2:$A2,$A2)=1,MAX($J$1:$J1)+1,IF(A2="",J1,""))

    in Sheet "Mon_Test"

    in C3

    =IFERROR(INDEX(Sheet3!$D:$D,MATCH(VLOOKUP($A3,Sheet3!$A:$J,10,0)&VLOOKUP(C$2,Sheet3!$L$1:$M$18,2,0),Sheet3!$I:$I,0)),0)

    Copy across and down

    Table in L &M could be a named range so defined only once.
    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. Nested IFs formula
    By Sprout07 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-05-2016, 05:42 PM
  2. Replies: 2
    Last Post: 08-24-2014, 04:56 AM
  3. [SOLVED] Nested IF formula
    By loulibelle in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 01-15-2013, 09:38 AM
  4. [SOLVED] Need a Nested Formula for ....................
    By gautamacharya in forum Excel General
    Replies: 5
    Last Post: 05-29-2012, 06:01 PM
  5. Replies: 2
    Last Post: 10-08-2009, 09:51 PM
  6. Nested IF formula
    By MAPepin in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-09-2009, 06:02 AM
  7. help on a nested countif/nested if formula
    By vickiemc in forum Excel General
    Replies: 2
    Last Post: 08-13-2008, 08:29 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