# Please help, I'm not sure what function combo to use to get the result I need.

Occasional Visitor

# Please help, I'm not sure what function combo to use to get the result I need.

I want to pull data from one sheet and combine the answer with a sum into another.

I have been making a ledger for a client. It has a 'PO sheet' where one column has a drop-down list for customer/client names and other columns including date entered, paid status (yes,no,overdue), date paid, amount, etc.

When certain customers have been paid as freelancers, I want this data to be transposed into the 'Payroll sheet' which is split monthly and between salaried staff and freelance staff.

So, for example Mr A. gets paid on 15th May £1500 and on 31st May £500 in expenses. Therefore these 2 payments to Mr A. are in a big list of payments on the 'PO Sheet' and have been paid in May. On the 'Payroll Sheet' in the row of May payments under the column Mr A. I need it to just say £2000.
Is this possible?

In summary, I think we are looking at two conditions:
Customer name matches on all in PO column with name on Payroll column
Date paid matches within the month in PO column to the month on Payroll row
Then all matches get added together

I managed (with help!) to get it working in GSheets using the following formula so maybe this one just needs 'tweaking' a little?

=ArrayFormula(SUMIF(TEXT(EOMONTH('PO Sheet'!K3:K,-1)+1,"MMMM")&'PO Sheet'!H3:H&'PO Sheet'!F3:F,B22:B33&C21:E21&"PAID",'PO Sheet'!G3:G))

Any help would be greatly appreciated.
Thanks.

1 Reply

# Re: Please help, I'm not sure what function combo to use to get the result I need.

Insert a pivot table.

Customer / Organisation in columns area.

Date Paid in rows area. Group by Month.

Total Paid in values area.

And possibly Paid Y/N? in filters area.