Need assistance please with complicated formula....

ValpoMan

New Member
Joined
Jun 25, 2010
Messages
46
Morning,

Thanks in advance! Ok here is the lay of the land.....

I have 3 tabs in a spreadsheet:

Tab 1 is just a simple summary sheet....this is where I am trying to put the formula.....

CO#1
CO#2
CO#3
CO#4
TOTAL
SGA
formula
formula
formula
formula
$ -
COR
formula
formula
formula
formula
$ -
TOTAL
$ -
$ -
$ -
$ -
$ -

<tbody>
</tbody>


Company 1 has a specific set of cost centers assigned to it but only ONE profit center....Company 2 has a different set and so on....

Tab 2 is a sheet with data exported from my accounting software....2 columns that I want the formula to reference are COST CENTER and AMOUNT

Here is a small sample of the layout:

Cost Center
Posting Date
Document Header Text
Name
Amount
1001312
6/30/2014
SD AC ATT MOBILITY CHARGE
AC ATT MOBILITY JUN 2014
39.09
1001312
6/1/2014
SD AC ATT MOBILITY CHARGE
AC ATT MOBILITY MAY 2014
-39.09
1001312
6/30/2014
SD AC VZ VERIZON WIRELESS
AC VERIZON WIRELESS JUN 2014
175.47
1001312
6/1/2014
SD AC VZ VERIZON WIRELESS
AC VZ VERIZON WIRELESS MAY 2014
-154.74
1001312
6/30/2014
SD ATT MOBILITY CHARGE MA
ATT MOBILITY MAY 2014
39.09
1001312
6/30/2014
SD VZ VERIZON WIRELESS CH
VERIZON WIRELESS MAY 2014
175.47
1001314
6/30/2014
SD AC VZ VERIZON WIRELESS
AC VERIZON WIRELESS JUN 2014
230.41

<tbody>
</tbody>


Tab 3 is a sheet that I want to serve as a lookup tab....columns important here are COST CENTER, FUNCTIONAL AREA (SGA/COR), and PROFIT CENTER.


Here is a small sample of the layout:

Cost Center
Company Code
Functional Area
Object Currency
Profit Center
1000001
Rev & Cost of Rev
1250
SERVICE
USD
10011
1000002
Sales Support
1250
SGADMIN
USD
10011
1000003
Documentation
1250
SERVICE
USD
10011
1000004
Training
1250
SERVICE
USD
10011
1000005
Client Services
1250
SERVICE
USD
10011
1000006
Account Management
1250
SGADMIN
USD
10011
1000007
Conversions
1250
SERVICE
USD
10011
1000008
Conversions
1250
SERVICE
USD
10011
1000009
Risk Management
1250
SGADMIN
USD
10011
1000010
Premier Ecom (Esol)
1250
SERVICE
USD
10011
1000011
Branch Capture
1250
SERVICE
USD
10011
1000012
Product Development
1250
SERVICE
USD
10011

<tbody>
</tbody>



So what I am trying to come up with in a formula is the following.....I will use TAB 1 Company #1 and the SGA cell for the sake of discussion

* Search TAB 3 for the profit center for company #1....look to see if it has a FUNCTIONAL AREA labeled as SGADMIN....if so then somehow retain the COST CENTER list in memory.....
* then take that list of cost centers and add the amounts for those cost centers in TAB 2

Sorry if this is messy....I wanted to try to provide a good picture of what I have.....
 

Excel Facts

How can you automate Excel?
Press Alt+F11 from Windows Excel to open the Visual Basic for Applications (VBA) editor.
If I were to lookup the Company #1, where would I find it in column 3? Which header?
I need company #'s and their profit centers adjacent to it to match (on tab 3)
 
Upvote 0
Company 1 is profit center 10120
Company 2 is profit center 10125
Company 3 is profit center 10230
Company 4 is a little trickier...they have 3 profit centers 10122, 10123, 10124

You will not see these profit centers in my small sample that I posted above of TAB 3 but that sheet is about a thousand lines long....

Here is the data from TAB 3 for company #1:

Cost Center Company CodeFunctional AreaObject CurrencyProfit Center
1001310Facilities KOP / LOP1150SGADMINUSD10120
1001322Client Support1150SERVICEUSD10120
1001328Business Analyst1150SERVICEUSD10120
1001331Core Technology1150SERVICEUSD10120
1001332Integration1150SERVICEUSD10120
1001335Project Mgt Office1150SERVICEUSD10120
1001337Quality Assurance1150SERVICEUSD10120
1001349Architecture1150SERVICEUSD10120
1001351Software Engineering1150SERVICEUSD10120
1001353SCM/SW Eng1150SERVICEUSD10120
1001354Tech Support/SW Eng1150SERVICEUSD10120
1001356ASP Operations1150SERVICEUSD10120
1001357Information/Tech (IT1150SERVICEUSD10120
1001358Accruals/Allocations1150SERVICEUSD10120

<tbody>
</tbody><colgroup><col><col><col><col><col><col></colgroup>
 
Upvote 0
Each of the companies/profit centers have about 10-15 cost centers that are unique to their company....they are mixed between SGADMIN and SERVICE (COR)....
 
Upvote 0

Forum statistics

Threads
1,216,028
Messages
6,128,393
Members
449,446
Latest member
CodeCybear

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