Forum Discussion
Need Help in finding Dependent table data
Hi All,
I have below columns in my dataset.
table_name - T1,T2,T3..,
tenant_name - A, B, C.. Unique values,
Operation - Read, Write, Other
Wave - Wave1, Wave2, Wave3, Wave4
I want to find dependent tenants for suppose, My data is like below:
| Wave | Tenant | Table | Operation |
| Wave1 | A | Tab1 | READ |
| Wave2 | B | Tab2 | WRITE |
| Wave3 | C | Tab3 | OTHER |
| Wave4 | D | Tab2 | READ |
| Wave1 | E | Tab1 | WRITE |
| Wave3 | F | Tab8 | WRITE |
Here, I want to find dependent tenants. For example Tenant A is reading the table in wave 1 but same table was writing by Tenant E in Wave1. I want to mark this Tenant A has dependent.
If table was reading and writing by one tenant, There is no other tenant using that table i want to mark it has Exclusive.
I am expecting out put like below:
| Tenant | Wave1 | Wave2 | Wave3 | Wave4 |
| A | 1 | 0 | 0 | 0 |
| B | 0 | 1 | 0 | 0 |
| C | ||||
| D | ||||
| E |
Here, Tenant A was dependent on 1 other tenants in wave1, Tenant A was not dependent on anyother tenant in Wave2.
Any leads will be appriciated!
Thanks in advance.
Greg_Deckler amitchandak Ritaf1983 lbendlin Ashish_Mathur #Need Help
2 Replies
- Sahir_MaharajSuper User
Hello Viswa11,
Can you please try the following:
DependentCount = SUMX( FILTER( 'YourTable', 'YourTable'[DependencyStatus] = "Dependent" ), 1 )- Viswa11Frequent Visitor
Hi Sahir_Maharaj ,
How can i find dependency table, I don't have any dependency column. For each individual operation I can do count and all but here I want to check is there any other tenant reading the table which was writting by other tenant then i want to mark has dependent table.
I have tried something like below.Dependent =IF ('Table'[Operation] = "WRITE",IF (CALCULATE (COUNTROWS ('Table'),FILTER ('Table','Table'[Operation] = "READ"&& 'Table'[TENANT_NAME] <> EARLIER ('Table'[TENANT_NAME])&& 'Table'[TABLE_NAME] = EARLIER ('Table'[TABLE_NAME]))) > 0,"Dependent","Not Dependent"),"Not Applicable")