Status
Not open for further replies.

rajesh1983

New Member
Joined
Jan 4, 2019
Messages
4
Table 1:
order IDNameLive DateHoursHours occupied as of today
121Rajesh01/19/201940?
122Rajesh01/19/201960?
123Rajesh01/19/201920?
124Rajesh02/16/2019100?
125Ramesh01/19/2019120?
126Ramesh01/19/2019160?
127Ramesh01/19/201925?
128Ramesh03/30/201930?
129Suresh01/19/201910?
130Suresh02/16/201980?
131Suresh02/16/201990?
132Suresh03/30/201930?
133Naresh01/19/201920?
134Naresh02/16/2019100?
135Naresh02/16/2019120?
136Naresh03/30/201960?

<colgroup><col span="2"><col><col><col></colgroup><tbody>
</tbody>

<colgroup><col><col><col><col></colgroup><tbody>
</tbody>

Table 2: (Data in table 2 will be constant, it is fixed)
Row IDReg_startReg_EndWork_StartWork_EndTest_StartTest_EndLive Date
111/28/201812/08/201812/09/201812/27/201812/29/201801/17/201901/19/2019
212/12/201812/22/201812/23/201801/10/201901/12/201901/31/201902/02/2019
312/26/201801/05/201901/06/201901/25/201901/26/201902/14/201902/16/2019
401/09/201901/20/201901/20/201902/07/201902/09/201902/28/201903/02/2019
501/22/201902/01/201902/02/201902/22/201902/23/201903/14/201903/16/2019
602/06/201902/16/201902/17/201903/07/201903/09/201903/28/201903/30/2019
702/27/201903/09/201903/10/201903/28/201903/30/201904/18/201904/20/2019
803/13/201903/23/201903/24/201904/11/201904/13/201905/02/201905/04/2019
903/27/201904/06/201904/07/201904/25/201904/27/201905/16/201905/18/2019
1004/09/201904/19/201904/20/201905/08/201905/10/201905/30/201906/01/2019
1104/30/201905/10/201905/11/201905/31/201906/01/201906/20/201906/22/2019
1205/14/201905/24/201905/25/201906/12/201906/14/201907/03/201907/06/2019
1305/29/201906/08/201906/09/201906/27/201906/29/201907/18/201907/20/2019
1406/12/201906/22/201906/23/201907/11/201907/13/201908/01/201908/03/2019
1507/03/201907/13/201907/14/201908/01/201908/03/201908/22/201908/24/2019
1607/16/201907/26/201907/27/201908/14/201908/16/201909/05/201909/07/2019
1707/31/201908/10/201908/11/201908/29/201908/31/201909/19/201909/21/2019
1808/14/201908/24/201908/25/201909/12/201909/14/201910/03/201910/05/2019
1908/27/201909/06/201909/07/201909/25/201909/27/201910/17/201910/19/2019
2009/11/201909/21/201909/22/201910/10/201910/12/201910/31/201911/02/2019
2109/24/201910/04/201910/05/201910/23/201910/25/201911/14/201911/16/2019
2210/08/201910/18/201910/19/201911/06/201911/08/201911/27/201911/30/2019
2310/23/201911/02/201911/03/201911/21/201911/23/201912/12/201912/14/2019

<colgroup><col><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>

1. Hours required between Reg_start and Reg_End is 5% of hours
2. Hours required between Work_Start and Work_End is 95% of hours
3. Hours required between Test_Start and Test_End is 5% of hours

My requirement is if any day i run the report in table1.Hours occupied as of today i should get the number of hours occupied.

let see couple of examples

Example 1 for order id 121, Hours is 40 and Live date is 01/19/2019.

Table 1:
order IDNameLive DateHoursHours occupied as of today
121Rajesh01/19/201940?

<colgroup><col><col><col><col><col></colgroup><tbody>
</tbody>

In table 2 this row matches with row ID 1
Row IDReg_startReg_EndWork_StartWork_EndTest_StartTest_EndLive Date
111/28/201812/08/201812/09/201812/27/201812/29/201801/17/201901/19/2019


<colgroup><col><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>
when i generate report as of today (Today date is 01/04/2019)
  • Reg_start and Reg_End dates are already passed so it should return 0 hours. (This has 5% value. 5% of 40 hrs)
  • Work_Start and Work_End dates are also already passed it should return 0 hours. (This has 90% value. 90% of 40 hrs)
  • Today's date falls between Test_Start and Test_End so it should return 2 hrs This has 5% value. 5% of 40 hrs =2hrs)


Example 2 for order id 124, Hours is 100 and Live date is 02/16/2019.

Table 1:

order IDNameLive DateHoursHours occupied as of today
124Rajesh02/16/2019100?

<colgroup><col><col><col><col><col></colgroup><tbody>
</tbody>

In table 2 this row matches with row ID 3.

Row IDReg_startReg_EndWork_StartWork_EndTest_StartTest_EndLive Date
312/26/201801/05/201901/06/201901/25/201901/26/201902/14/201902/16/2019


<colgroup><col><col><col><col><col><col><col><col></colgroup><tbody>
</tbody>

when i generate report as of today (Today date is 01/04/2019)

  • Today's date falls between Reg_start and Reg_End dates, hence it should return 5 hours. (This has 5% value. 5% of 100 hrs= 5hrs)
  • Work_Start and Work_End dates in future, hence it should return 0 hours. (This has 90% value. 90% of 100 hrs)
  • Test_Start and Test_End dates is also in future, hence it should return 0 hrs (This has 5% value. 5% of 100 hrs ).

please help me to achieve this.
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result
Duplicate https://www.mrexcel.com/forum/excel-questions/1082602-need-excel-help.html

Please do not post the same question multiple times. All clarifications, follow-ups, and bumps should be posted back to the original thread.
Per forum rules, posts of a duplicate nature will be locked or deleted (rule 12 here: Forum Rules).

Note that sometimes posts from new users require Moderator approval before you can see them on the public forums. When this happens, you should see a message to that effect when you try to post it.
Please be patient and do not attempt to post the question again.

 
Upvote 0
Status
Not open for further replies.

Forum statistics

Threads
1,215,839
Messages
6,127,204
Members
449,368
Latest member
JayHo

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