Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Team,
Good Morning. I have a Data Model like mentioned below. WI_Link , WorkItem , WorkItemId, State, Type ,Parent are from One Table, Tree Level is from Different Table , Region ID From different Table Active is From Different Table connected with Each other in Data Model.
| Table | |||||||
| - | |||||||
| WI_Link | WorkItem | Tree Level1 | State | Type | Active | Parent | Region ID |
| 1 | 1 | Second (Active) 1 | Parent | Active | TRUE | 0 | 2.2 |
| 2 | 1.1 | Parent(Active) 1 | Child | Active | TRUE | 1 | 2.2 |
| 3 | 1.2 | Parent(Active) 1 | Child | Active | TRUE | 1 | 2.2 |
| 4 | 1.3 | Parent(Active) 1 | Child | Active | TRUE | 1 | 2.2 |
| 5 | 2 | Parent(Active) 2 | Parent | Active | TRUE | 0 | 2.3 |
| 6 | 2.1 | Parent(Active) 2 | Child | Active | TRUE | 2 | 2.2 |
| 7 | 2.2 | Parent(Active) 2 | Child | Active | TRUE | 2 | 2.3 |
I need to Show the Count based on Both Parent and Region as If Select 2.2
| WI Item No | Child Count |
| 1 | 3 |
| Unassigned | 1 |
Unassigned that is Row No. 6
If I select 2.3 then it should show
| WI Item | Child Count |
| 2 | 1 |
Note : There is a problem in Tree Level1 as for the Workitem 1 the name should be Parent(Active) 1 instead of second(Active) 1. So for this I Created a tow table mentioned below.
| Parent | ||||||||
| WI_Link | WorkItem | Tree Level1 | State | Type | Active | Workitem as Parent | Region ID | Key |
| 1 | 1 | State-Type & WorkItem | Parent | Active | TRUE | 1 | 2.2 | 1 & 2.2 |
| 5 | 2 | State-Type & WorkItem | Parent | Active | TRUE | 2 | 2.3 | 2 & 2.3 |
| Child : | ||||||||
| WorkItem | Tree Level1 | State | Type | Active | Parent | Region ID | Key | |
| 1.1 | State-Type & Parent | Child | Active | TRUE | 1 | 2.2 | 1 & 2.2 | |
| 1.2 | State-Type& Parent | Child | Active | TRUE | 1 | 2.2 | 1 & 2.2 | |
| 1.3 | State-Type& Parent | Child | Active | TRUE | 1 | 2.2 | 1 & 2.2 | |
| 2.1 | State-Type& Parent | Child | Active | TRUE | 2 | 2.2 | 2 & 2.2 | |
| 2.2 | State-Type | Child | Active | TRUE | 2 | 2.3 | 2 & 2.3 | |
Now the Answer is coming like this
| Region 2.2 | ||
| WI Item | Child Count | |
| 1 | 3 | |
| Unassigned | 1 | Not Showing in My Count as I linked with Key Field |
| Region 2.3 | ||
| WI Item No | Child Count | |
| 2 | 1 |
Attached for the Reference.
Please do the needful. Its very Urgent