I have two excel sheets, I am trying to find all user details along with request IDs that are accessed on a particular date and time range.
Sheet 1: Request
| A | B | C | D | E |
|---|---|---|---|---|
| User | Request ID | Startdate | enddate | Business reason |
| 100 | 1234567 | Jul 01, 2022 03:24:11 | Jul 01, 2022 06:10:11 | SRQ123456 |
| 101 | 1234568 | Jul 01, 2022 06:24:11 | Jul 01, 2022 08:24:11 | CHG123456 |
Sheet 2: Access details
| A | B | C | D |
|---|---|---|---|
| OBJECTNAME | ACTION | ACCESSBY | ACCESSTIME |
| Business User | Update | 100 | Jul 01, 2022 05:59:12 |
| Workflow | Update | 100 | Jul 01, 2022 06:05:20 |
| Roles Add Workflow | Update | 100 | Jul 01, 2022 06:10:32 |
| SFA | Delete | 101 | Jul 01, 2022 06:24:12 |
Tried the below code result to find out the record within the date range but I am not able to get the entire row details of sheet1:Request. I have used Name manager from the formula to store the value of Startdate, enddate, and User.
=IF(COUNTIFS(Startdate,"<="&D3,enddate,">="&D3,User,C3)>0,"Yes","No")
Sheet 2: Access details
| A | B | C | D | E |
|---|---|---|---|---|
| OBJECTNAME | ACTION | ACCESSBY | ACCESSTIME | |
| Business User | Update | 100 | Jul 01, 2022 05:59:12 | Yes |
| Workflow | Update | 100 | Jul 01, 2022 06:05:20 | Yes |
| Roles Add Workflow | Update | 100 | Jul 01, 2022 06:10:32 | No |
| SFA | Delete | 101 | Jul 01, 2022 06:24:12 | Yes |
The expected output in Sheet2 should be as below
| A | B | C | D | E | F | G | H | I | J |
|---|---|---|---|---|---|---|---|---|---|
| OBJECTNAME | ACTION | ACCESSBY | ACCESSTIME | User | Request ID | Startdate | enddate | Business reason | |
| Business User | Update | 100 | Jul 01, 2022 05:59:12 | Yes | 100 | 1234567 | Jul 01, 2022 03:24:11 | Jul 01, 2022 06:10:11 | SRQ123456 |
| Workflow | Update | 100 | Jul 01, 2022 06:05:20 | Yes | 100 | 1234567 | Jul 01, 2022 03:24:11 | Jul 01, 2022 06:10:11 | SRQ123456 |
| Roles Add Workflow | Update | 100 | Jul 01, 2022 06:10:32 | No | Record not matched | ||||
| SFA | Delete | 101 | Jul 01, 2022 06:24:12 | Yes | 100 | 1234568 | Jul 01, 2022 06:24:11 | Jul 01, 2022 08:24:11 | CHG123456 |

