How would I determine the employees working at the time of each retail transaction by comparing that transaction timestamp with employee shift times?

l3theri0

New Member
Joined
Sep 14, 2022
Messages
1
Office Version
  1. 2021
Platform
  1. Windows
We allocate tips and sales bonuses at our company based on the time frames an employee worked. If someone comes in and buys our product at 1 PM, the various employees on the clock at the time of that transaction will receive a % of that sale and a share of any tips from the transaction (both split evenly between any employees clocked in).

---

**I have 2 tabs of data**:

* The Time Entries tab has individual clock in/out entries for the pay period - formatted like this:
* The Transactions tab has individual sales transactions for the pay period - formatted like this:
I was able to use SUMIFS to sum the Net Total (column C from my second screenshot) of transactions for each clock in/out time frame on the Time Entries tab, but this double counts transactions because we have multiple employees clocked in at the same time. Instead, I think I have to start with the Transactions tab and somehow associate a set of employees with each sale.

---

**Here are the alternative ways I've looked at formatting this:**

* I created a tab for the entire pay period from 12 AM of the first day through 11:59 PM of the last day, and each row represents a 10 minute increment. Then I summed the Total Sales from each 10 minute period based on the data from the Transactions tab. Here's what it looks like: . I created columns for each employee that would have formulas to determine if an employee was clocked in during that time frame (simple True/False would work), but I'm not sure where to go from there.

* On the Transactions tab, I added columns for each employee similar to the previous paragraph and need help with a formula that would determine whether the sale was during an employee's shift based on its timestamp. Here's what it looks like: . It would give a True/False response based on the employee's name in the column header matching with the employee's name associated with the time entry, so if multiple employees are clocked in at the time of the transaction, then those employees would all return Yes.

If I can get either of those 2 methods to return True/False answers by employee, it's simple math to divide up their tips and sales bonuses from there. What do you think? Is there a better way to slice this data?

Thanks!
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Check column K is the sample data below -

All Records.xlsb
ABCDEFGHIJK
1Emplyee NameDayTime inTime OutHoursTimeRegisterNetTipsEmployee Working
2JoeThursday44,568.3244,568.6608:15:0044,568.47Register 933.902.00Joe
3Employee244,820.2344,820.7813:11:5544,820.70Register 8Employee2
Sheet2
Cell Formulas
RangeFormula
E2:E3E2=D2-C2
K2:K3K2=LET(Start,XLOOKUP(G2,$C$2:$C$3,$A$2:$A$3,"",-1,1),Stop,XLOOKUP(G2,$D$2:$D$3,$A$2:$A$3,"",1,1),IF(Start=Stop,Start,"Not Found"))
 
Upvote 0

Forum statistics

Threads
1,224,820
Messages
6,181,161
Members
453,021
Latest member
Justyna P

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