Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a problem regarding the Nested Set Analysis below:
DB:
WorkOrderID | WorkOrder_Date | Machine | Install_Date |
WO-1 | 201508 | Machine1 | 201502 |
WO-2 | 201509 | Machine2 | 201503 |
WO-3 | 201510 | Machine3 | 201504 |
WO-4 | 201511 | Machine4 | 201505 |
WO-5 | 201512 | Machine5 | 201506 |
WO-6 | 201601 | Machine6 | 201507 |
WO-7 | 201602 | Machine7 | 201508 |
WO-8 | 201603 | Machine8 | 201509 |
I need to calculate the Past three Months WorkOrder QTY which the Machine Install_date must be the Past six Months.
Calculation Condition: the Machine Install_date must be the Past six Months for WorkOrder.
Please help to provide the expression. Many thanks.
What is the expected output for the above sample?
Maybe somthing like
=Count(DISTINCT {<WorkOrderID = {"=AddMonths(Date#(Install_Date,'YYYYMM'),5)<Date#(WorkOrder_Date,'YYYYMM')"}>} WorkOrderID)
the WorkOrder QTY.
For example:
if I select WorkOrder_date '201603', it need to look whether the Machine Install_date is last 6 six Months, then calculate the past three related WorkOrder QTY.
Please help to advise whether it need to add the WorkOrder_date. Because I also need to calculate the Past three Months WorkOrder .