Auto populate a table using two filtered ranges from another table

%3CLINGO-SUB%20id%3D%22lingo-sub-1849483%22%20slang%3D%22en-US%22%3EAuto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849483%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%20sorry%20in%20advance%20if%20this%20has%20already%20been%20posted.%20I%20was%20wondering%20if%20there%20is%20a%20way%20to%20autopopulate%20a%20table%20using%20a%20separate%20table%20with%20a%20custom%20filtered%20range%20on%20two%20columns.%3C%2FP%3E%3CP%3EIn%20the%20example%20attached%2C%20I%20would%20like%20to%20auto%20populate%20Table%20A%20with%20the%20Totals%20for%20Data%201%2C2%2C3%20at%201m%2C2m%2C3m%20depth%20intervals%20and%20for%20units%201%20and%202%20using%20all%20samples%20from%20Table%20A.%26nbsp%3B%3C%2FP%3E%3CP%3EI%20tried%20using%20%3D%20sign%2C%20but%20this%20changes%20the%20total%20every%20time%20I%20change%20the%20filter%20(which%20may%20require%20multiple%20spreadsheets%20to%20keep%20the%20value%20at%20the%20custom%20filters)%20and%20I%20am%20unsure%20what%20function%20I%20can%20use%20that%20gives%20a%20total%20data%20value%20for%20the%20depth%20range%20and%20unit%20without%20changing%20when%20the%20two%20filters%20change%20for%20the%20other%20intervals.%26nbsp%3B%3C%2FP%3E%3CP%3EAny%20help%20will%20be%20much%20appreciated!%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1849483%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Etraining%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1849619%22%20slang%3D%22en-US%22%3ERe%3A%20Auto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849619%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F854257%22%20target%3D%22_blank%22%3E%40Crimzo%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EI%20don't%20really%20understand%20your%20question%2C%20so%20this%20may%20be%20off.%20In%20the%20attached%20version%2C%20I%20entered%20a%20formula%20in%20C3%2C%20then%20used%20Paste%20Formulas%20to%20paste%20it%20to%20the%20other%20cells.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1849745%22%20slang%3D%22en-US%22%3ERe%3A%20Auto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849745%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F854257%22%20target%3D%22_blank%22%3E%40Crimzo%3C%2FA%3E%26nbsp%3BAs%20a%20variant%2C%20a%20Pivot%20Table%20might%20do%20what%20you%20ask%20for%2C%20though%20in%20a%20slightly%20different%20format.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1849785%22%20slang%3D%22en-US%22%3ERe%3A%20Auto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849785%22%20slang%3D%22en-US%22%3EHi%20Hans%20Vogelaar%2C%20thank%20you%20for%20your%20response!%20Sorry%20the%20question%20is%20poorly%20worded%2C%20I%20think%20I%20am%20struggling%20to%20get%20the%20right%20words.%20The%20formula%20works%20great%2C%20but%20is%20there%20a%20way%20to%20put%20the%20Total%20value%20(I%20meant%20to%20put%20SUM%20rather%20than%20SUBTOTAL)%20that%20is%20in%20the%20grey%20highlights%20in%20table%20A%20into%20the%20Table%20B%3F%20i.e.%20the%20total%20for%20Unit%201%20at%201%20m%20is%203%20for%20Data%201%2C%20Data%202%20and%20Data%203.%20Then%20for%20Unit%201%20at%202m%20the%20total%20is%201%20for%20Data%201%2C%20and%202%20for%20Data%202%20and%203.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1849787%22%20slang%3D%22en-US%22%3ERe%3A%20Auto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849787%22%20slang%3D%22en-US%22%3EHi%20Riny_van_Eekelen%2C%20thank%20you%20for%20your%20reply%20and%20suggestion%2C%20I%20haven't%20used%20Pivot%20Tables%20but%20will%20give%20it%20a%20look.%20I%20poorly%20worded%20by%20above%20question%20and%20meant%20to%20ask%20if%20the%20grey%20highlighted%20totals%20can%20be%20put%20into%20the%20information%20rather%20than%20the%20raw%20data%20per%20depth%20and%20unit.%20i.e.%20Unit%201%20at%201%20m%20has%20a%20total%20data%201%20value%20of%203.%20Will%20see%20if%20I%20can%20do%20this%20with%20the%20pivot%20plot!%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1849812%22%20slang%3D%22en-US%22%3ERe%3A%20Auto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849812%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F854257%22%20target%3D%22_blank%22%3E%40Crimzo%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EHow%20about%3C%2FP%3E%0A%3CP%3E%3DCOUNTIFS('Table%20A'!D%2412%3AD%2422%2C%22%26lt%3B%26gt%3B%22%2C'Table%20A'!%24A%2412%3A%24A%2422%2COFFSET(%24A3%2C-MOD(ROW()%2B1%2C4)%2C0)%2C'Table%20A'!%24C%2412%3A%24C%2422%2C%24B3)%3C%2FP%3E%0A%3CP%3ESee%20the%20attached%20version.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1849813%22%20slang%3D%22en-US%22%3ERe%3A%20Auto%20populate%20a%20table%20using%20two%20filtered%20ranges%20from%20another%20table%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1849813%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F854257%22%20target%3D%22_blank%22%3E%40Crimzo%3C%2FA%3E%26nbsp%3BLike%20so%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Occasional Contributor

Hi, sorry in advance if this has already been posted.

 

I was wondering if there is a way to autopopulate a table using a separate table total with a custom filtered range on two columns.

 

In the example attached, I would like to auto populate Table A with the Totals (grey highlighted) for Data 1,2,3 at 1m,2m,3m depth intervals and for units 1 and 2 using all samples from Table A. i.e. for unit 1 at 1 m the total is 3, unit 2 at 1m is 3. or unit 2 at 2m has a total of 2. Or with example 2, can the Lower and Upper bounds be stated in the same way? 

 

Any help will be much appreciated! 

10 Replies
Highlighted

@Crimzo 

I don't really understand your question, so this may be off. In the attached version, I entered a formula in C3, then used Paste Formulas to paste it to the other cells.

Highlighted

@Crimzo As a variant, a Pivot Table might do what you ask for, though in a slightly different format.

Highlighted
Hi Hans Vogelaar, thank you for your response! Sorry the question is poorly worded, I think I am struggling to get the right words. The formula works great, but is there a way to put the Total value (I meant to put SUM rather than SUBTOTAL) that is in the grey highlights in table A into the Table B? i.e. the total for Unit 1 at 1 m is 3 for Data 1, Data 2 and Data 3. Then for Unit 1 at 2m the total is 1 for Data 1, and 2 for Data 2 and 3.
Highlighted
Hi Riny_van_Eekelen, thank you for your reply and suggestion, I haven't used Pivot Tables but will give it a look. I poorly worded by above question and meant to ask if the grey highlighted totals can be put into the information rather than the raw data per depth and unit. i.e. Unit 1 at 1 m has a total data 1 value of 3. Will see if I can do this with the pivot plot!
Highlighted

@Crimzo 

How about

=COUNTIFS('Table A'!D$12:D$22,"<>",'Table A'!$A$12:$A$22,OFFSET($A3,-MOD(ROW()+1,4),0),'Table A'!$C$12:$C$22,$B3)

See the attached version.

Highlighted

@Crimzo Like so?

 

Highlighted
Hi Hans Vogelaar, that works great, thank you so much!
Highlighted
Hi Riny_van_Eekelen, this works really well thank you! Will definitely start using pivot tables!
Highlighted

@Hans Vogelaar Hi Hans Vogelaar, the formula you gave above rightly calculates the Countif per cell, is there a way to link that to the grey box and use the value in there? I ask this, as I would like to do the same for the Lower and Upper Bounds rather than total of the data. Would I replicate your formula and add the calculation steps at the start? 

Highlighted

@Crimzo 

In D8: =COUNT(D$16:D$26)

In D9: =AVERAGE(D$16:D$26)

In D10: =STDEV(D$16:D$26)

 

Fill right to column F