+ Reply to Thread
Results 1 to 7 of 7

Indirect formula

  1. #1
    Registered User
    Join Date
    10-18-2017
    Location
    NYC NY, USA
    MS-Off Ver
    microsoft office 2013
    Posts
    3

    Indirect formula

    Can someone please explain the formula below for me?....
    INDIRECT ("'"&BE$6&"'!"&"$G:$G)
    Last edited by BuckeyeGH; 10-18-2017 at 09:12 AM.

  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
    43,984

    Re: Indirect formula

    return the values in column G from the sheet which is named in cell BE6. I assume that it is part of a larger formula...

    It may be very slow, as it uses a whole column reference...
    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
    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
    43,984

    Re: Indirect formula

    You sent me a PM saying that was the complete formula (please keep conversations in your thread...).

    In that case, I have no idea what it is for. If entered as an orinary formula, it will retun zero. If enered as an array formula, it returns the value in G1 of the sheet referred to. What were you hoping that it would do?

  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
    43,984

    Re: Indirect formula

    I misread your pm...

    Here is your formula, broken down into bite-sized chunks…

    =IF(ISERROR(
    SUMIFS(INDIRECT("'"&BE$6&"'!"&"$G:$G"),INDIRECT("'"&BE$6&"'!"&"$R:$R"),$A39,INDIRECT("'"&BE$6&"'!"&"$F:$F"),"<>52711",INDIRECT("'"&BE$6&"'!"&"$C:$C"),10)),
    Pick up the sheetname from BE6 and sum the values in column G where…
    The value in R is equal to the value in a39, and
    The value in F is anything other than 52711 and
    The value in C is 10

    If all of that returns an error
    0, return zero; otherwise
    SUMIFS(INDIRECT("'"&BE$6&"'!"&"$G:$G"),INDIRECT("'"&BE$6&"'!"&"$R:$R"),$A39,INDIRECT("'"&BE$6&"'!"&"$F:$F"),"<>52711",INDIRECT("'"&BE$6&"'!"&"$C:$C"),10)) return the calculated value.

    PLUS … a similar formula
    +IF(ISERROR(
    SUMIFS(INDIRECT("'"&BE$4&"'!"&"$A$30:$EO$30"),INDIRECT("'"&BE$4&"'!"&"$A$4:$EO$4"),BE$5,INDIRECT("'"&BE$4&"'!"&"$A$5:$EO$5"),$A39)),
    0,
    SUMIFS(INDIRECT("'"&BE$4&"'!"&"$A$30:$EO$30"),INDIRECT("'"&BE$4&"'!"&"$A$4:$EO$4"),BE$5,INDIRECT("'"&BE$4&"'!"&"$A$5:$EO$5"),$A39))

    PLUS another similar formula.
    +IF(ISERROR(
    SUMIF(INDIRECT("'"&BE$6&" "&$A$31&"'!"&"H:H"),$A39,(INDIRECT("'"&BE$6&" "&$A$31&"'!"&"I:I")))),
    0,
    SUMIF(INDIRECT("'"&BE$6&" "&$A$31&"'!"&"H:H"),$A39,(INDIRECT("'"&BE$6&" "&$A$31&"'!"&"I:I"))))

    It’s a mess. Whole column references will be slow, unless you do have more than 1,000,000 rows. Also the clumsy use of IF(ISERROR… an Excel 2003 and before thing will slow it up further.

    I’d use:

    =IFERROR(SUMIFS(INDIRECT("'"&BE$6&"'!"&"$G:$G"),INDIRECT("'"&BE$6&"'!"&"$R:$R"),$A39,INDIRECT("'"&BE$6&"'!"&"$F:$F"),"<>52711",INDIRECT("'"&BE$6&"'!"&"$C:$C"),10),0)+IFERROR(SUMIFS(INDIRECT("'"&BE$4&"'!"&"$A$30:$EO$30"),INDIRECT("'"&BE$4&"'!"&"$A$4:$EO$4"),BE$5,INDIRECT("'"&BE$4&"'!"&"$A$5:$EO$5"),$A39),0)+IFERROR(SUMIF(INDIRECT("'"&BE$6&" "&$A$31&"'!"&"H:H"),$A39,(INDIRECT("'"&BE$6&" "&$A$31&"'!"&"I:I"))),0)

    AND I would change all the whole column references to something sensible.

  5. #5
    Registered User
    Join Date
    10-18-2017
    Location
    NYC NY, USA
    MS-Off Ver
    microsoft office 2013
    Posts
    3
    Thanks so much Glenn. I'm using your formula and it's working great. The only problem is I'm trying to exclude 2 rows from the sheet BE$4 and also exclude 52712 in addition to 52711 in she BE$6. How can I factor these changes into your suggested formula? And finally, can you please explain INDIRECT("'"&BE$6&" "&$A$31&"'!"&"H:H"),$A39 for me, as it's not quite the same as the ones you explained earlier. Thanks
    Last edited by AliGW; 10-23-2017 at 12:10 PM. Reason: Name of member who helped changed from Ken to Glenn.

  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
    43,984

    Re: Indirect formula

    This is now nigh on impossible without seeing the sheet and also knowing what rows you want to exclude. Can you post your sheet, or a suitably anonmyised sample?

    Unfortunately the attachment icon doesn't work at the moment. So, to attach an Excel file you have to do the following: Just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

  7. #7
    Registered User
    Join Date
    10-18-2017
    Location
    NYC NY, USA
    MS-Off Ver
    microsoft office 2013
    Posts
    3

    Re: Indirect formula

    I'm not able to attach the spreadsheet because it's in my class' SharePoint site and for unknown reasons, the spreadsheet can not be downloaded or copied.
    I have a formula question in the attached file. Thx
    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] My formula sumif/indirect formula is working perfect..except everything is 1 row off!
    By Nyolls in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-23-2015, 01:12 PM
  2. [SOLVED] INDIRECT Function with multiple sheets - SUMIF, INDIRECT & MATCH
    By DJDRU in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-07-2014, 08:42 AM
  3. adding Indirect formula to my current sum if array formula
    By Eastbay2 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 05-13-2013, 09:41 AM
  4. Sum of indirect sheet names with multiple cells (SUM, INDIRECT,SHEETNAME in cell)
    By a1b2c3d4e5f6g7h8 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 02-12-2013, 08:42 AM
  5. [SOLVED] INDIRECT Query: How to incorporate INDIRECT to choose between two ranges?
    By The_Snook in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 10-18-2012, 06:28 AM
  6. Replies: 1
    Last Post: 02-10-2012, 02:53 AM
  7. [SOLVED] Allow EXCEL INDIRECT(ADDRESS()) and INDIRECT(RANGE()) functions
    By Mike Barlow in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 07-05-2005, 11:05 PM

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