filter function with manipulation of cell location

ExcelNewbie2020

Active Member
Joined
Dec 3, 2020
Messages
295
Office Version
  1. 365
Platform
  1. Windows
Is filter function can rearrange the cell location? for example with the table provided. i want to filter year 2010, but i want the result, the 1st column the year, 2nd the name and 3rd the dept.


hlink.xlsm
ABCDEFGHIJK
1NAMEDEPTYEARFILTER RESULT2010
2AAOPS2010YEARNAMEDEPT
3BBSALES20102010AAOPS
4CCMKTG20122010BBSALES
5DDOPS2011
6EESALES2012
7FFMKTG2011
8
9
10
11
12
13
14
15
Sheet12
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
Maybe:
Book1
ABCDEFGHIJ
1NAMEDEPTYEARFILTER RESULT2010
2AAOPS2010YEARNAMEDEPT
3BBSALES20102010OPSAA
4CCMKTG20122010SALESBB
5DDOPS2011
6EESALES2012
7FFMKTG2011
Sheet1
Cell Formulas
RangeFormula
F3:H4F3=CHOOSECOLS(FILTER(A2:C7,C2:C7=$J$1),3,2,1)
Dynamic array formulas.


Or maybe:
Excel Formula:
=CHOOSECOLS(FILTER(A2:C7,C2:C7=$J$1),SEQUENCE(,3,3,-1))
 
Upvote 0
Solution
Maybe:
Book1
ABCDEFGHIJ
1NAMEDEPTYEARFILTER RESULT2010
2AAOPS2010YEARNAMEDEPT
3BBSALES20102010OPSAA
4CCMKTG20122010SALESBB
5DDOPS2011
6EESALES2012
7FFMKTG2011
Sheet1
Cell Formulas
RangeFormula
F3:H4F3=CHOOSECOLS(FILTER(A2:C7,C2:C7=$J$1),3,2,1)
Dynamic array formulas.


Or maybe:
Excel Formula:
=CHOOSECOLS(FILTER(A2:C7,C2:C7=$J$1),SEQUENCE(,3,3,-1))
both worked.. thank you
 
Upvote 0
.. yet another
Excel Formula:
=SORTBY(FILTER(A2:C7,C2:C7=J1),{3,2,1})
 
Upvote 1

Forum statistics

Threads
1,216,075
Messages
6,128,659
Members
449,462
Latest member
Chislobog

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top