FILTER function output, replace 1st character of each item in field

craigexcel

Active Member
Joined
Jun 28, 2006
Messages
295
Office Version
  1. 2016
Platform
  1. Windows
I'm working with SAP data, which includes Cost Center (numeric), Activity Type (alphanumeric), and rates.
Cost Centers are like 210000, 210010, 210020, and 210030.
Activity Types are like 1AACA1, 1ACOC2, 1ANBC0, 9AACC2, 9ACON2, 9ASSP1.

I create a pivot table to include these 3 elements. The item in the "Row" field of the pivot table is concatenated, like 210000_1AACA1. (It could just as easily be 2 separate fields, instead of a concatenated value, if that would better support a solution for this.) The concatenated items can be any combination of Cost Center and Activity Type (1????? and 9?????).

The problem I'm trying to solve is this: I have taken the approach to try to use the FILTER function on the pivot table data to get the data I want. The rates for all 1????? and 9????? Activity Types need to remain as is, but for any 1????? Activity Type only, I also need (in the result), converted values like 2?????, with an associated overtime rate calculated as the base rate * 1.5.

It would be ideal if this could all be incorporated in the pivot table results, but as referenced, if that doesn't seem possible, the FILTER function works too.

example pivot table data (since I don't have the ability @ work to download the tool to include the Excel data image):

Cost Ctr Act Type Rate
210000 1AACA1 10.00
210000 9AACC2 15.00
210010 1ANBC0 12.00
210030 9ASSP1 16.00
210000 2AACA1 15.00 (210000 / 1AACA1 $10 rate * 1.5)
210010 2ANBC0 18.00 (210010 / 1ANBC0 $12 rate * 1.5)

Windows 10 Enterprise
64-bit
Office 365

I tried using the REPLACE function for the 'include' argument of the FILTER function, using <Ctrl><Shift><Enter>, without success.
I would appreciate any thoughts you may have to solve this, or resources that might suggest some ways to do this. Thanks.
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.

Forum statistics

Threads
1,214,530
Messages
6,120,071
Members
448,943
Latest member
sharmarick

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