dax relationships
5 TopicsPower BI Report Builder: group unrelated data
Goal: Hi, I am a bit unfamiliar with Power BI Report Builder/ Report Server. The goal is to have multiple datasets "grouped" by one multivalue parameter for a print out based on a selected multivalue parameter. Example - FarmHouse: I have multiple chickens from my chicken dataset who own multiple eggs on an egg table. They also store which henhouse they are from in a henhouse table. I would like to select multiple chickens and display a print out per chicken of their eggs and henhouses grouped per chicken. Contraints: Power Bi Datasets DAX Problem: I cannot have static inner members when grouping or encapsulating data that is unrelated. At base, data is unrelated within Report Builder. I have had some success using TREATAS to relate/filter results in a single example, but that is as far as I have come. Any suggestions, advice, resources, or questions are welcomed. Thank you!979Views1like2CommentsCount number of rows in another table with same ID
Hi All I have a quite simple (I think) DAX question, that I hope you can help me with. Tried to find similar in the forum, without luck. I hav two tables: Table 1 Product Customer ReservationID A 1 123 A 5 234 B 5 234 C 7 345 C 9 456 Table 2 Customer ReservationID 1 123 2 123 3 123 4 123 5 234 6 234 7 345 8 345 9 456 10 567 11 567 12 678 There is a relation between the to tables, on Customer - Many-to-one. Now: If I have a filter on table 1 with Product = "A", I wan't to create a meassure to count how many related customers in Table2 are on a reservation where another customer bought this product. So, in above example, if I filter on product "A", I can see that 6 customers are on a reservations that bought this product and thereby my desired result is "6". If there is no filtering done on product level, I expect the result to be 11, as there is 11 customers on the reservations which have got any kind of product. (ie. reservation 234 bought two products, customer 10-12 is on reservations that are not present in table1) I've been walking around, some Countrows, including a calculate with allselected, but I haven't been able to find the solution yet. Looking forward to see your suggestions. Thanks in advance!Solved3.3KViews0likes6CommentsProtecting data with a password inserted into a text filter - high level, feedback appreciated!
Hello! For the past few weeks, I've been working on doing what the title says, revealing only sections of data to users who input an ID, revealing all related data in our visuals. Here is an example of what this table might look like: ID MetricToView ReadableName_1342135 23 OtherName_1341147 27 Here are the approaches I've explored: Row-level security Might be the path forward, but our thought was this won't work because we want new users to dynamically get access to rows of data - Power Automate doesn't provide that functionality and it looks like this would require a lot of upkeep to continually manually assign users Using a free text filter/slicer visual - This doesn't work in a simple way for the following combination of reasons All possible options for a field are listed and can't be hidden (since this is somewhat sensitive data, we don't want users to be able to pick an ID that is not theirs to see data that isn't theirs) The search uses "contains" to match any substring to the closest string in a column of a table The search doesn't allow for us to set a "single selection mode" - This in combination of the above point removes one possible solution I attempted Best visuals to use for this problem Using Smart Filter Pro - This will work out of the box for a mid-high yearly fee (has options to hide suggestions and enforce exact match) Using Text Filter - This is great because it is free and doesn't list suggestions, but has the problems listed above (1.2 and 1.3, using 'contains' to search and not allowing single selection mode) Other options - I looked at a ton of other visuals (I believe every other option), and all options had dropdowns for a selection which we don't want Ways I've approached this problem to try to solve it using the free Text Filter visual: Most realistic, least work, ugly - Remove the user readable portion of the passcode IDs The readable portion is useful for someone to be able to recognize their ID, but with the default filter behavior, if I suspect that "John" has some data, I can search "John" and I might be able to view that If this "solution" is followed, now there would just be a string of digits as IDs, so even if someone enters '132' and that matches to a single ID, I won't know who it belongs to or even if that is a single match or multiple matches I still don't love this solution because we don't want users to compare their metric to another user, so even getting an idea of other values that have been given isn't favorable Convoluted but cool, two routes to a solution that I've explored and found not possible - Creating 2 duplicates of each password ID with the first or last character replaced by an underscore - https://community.fabric.microsoft.com/t5/Power-Query/write-unique-password-to-see-the-data-of-that-partucal-person/m-p/1152259 This would work if single selection was possible, as some substring input into the text box would now latch on to the false password, and no data would be shown As of now, multiple selection is the only option with this visual, so multiple matching rows are returned, and if any row contains valid data, the visuals are populated Then, I tried creating a measure that would count the number of selected rows - this correctly found all rows that were filtered on by the text search visual, but there is no secure way to stop the visuals from showing in this case I know we can change the transparency/color of visuals, but aren't they still screen-readable or accessible in different color schemes of a browser? I know this is a lot of context, but my question is: Is there a way to password protect some data using this text filter with the knowledge that it doesn't perform an exact match, and that there is no option to set a single match? - Thank you! One path that I think might yield a solution is if we can have the text filter search one table (filled with false, distractor IDs), and if no match is found, search the real password table - I just don't know if this is possible One other path could be some other manipulation of visuals (or filtering if possible) based on the value of a measure which checks if there is truly one match or not Anything else - If row-level security can be automated somehow, please let me know too! - otherwise, the other solutions I have listed might be what I pursue729Views0likes1CommentHow to force or make a measure to use the relationship in DAX
Hi all, I have two "Many to One" relationships in the Tabular Model to Dates table where Table1 is a Fact table and Dates is a dimensin table as mentioned below: 'Table1'[Date Key] --> 'Dates'[Date Key] 'Table1'[ReceiptDateKey] --> 'Dates'[Date Key] I have a measure X which is SUM ( 'Table1'[Sale] ), I wanted to force or make this measure X to use the relationship 'Table1'[ReceiptDateKey] --> 'Dates'[Date Key] in the DAX calculations. How I can achieve this, please can you help with DAX Command. Regards, Ranjan.Solved6KViews0likes5Comments