Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all,
My multidimensional db has chart of accounts dimension (ragged), and when I attempt to import data for one of the account's children, instead of one Account column I get all Levels in multiple columns instead:
Query I use:
WITH MEMBER [Measures].Dummy as 100
select
{ [Measures].[Dummy] } ON 0,
{ [Account].[H1].[100399_Rev_Ext_ex_ex].children } ON 1
FROM [Finance]
I was writing this query in SSMS, where result was somewhat different, with only one column for accounts. I wonder if there is a way to achieve same result as in SSMS in PBI (and not only for getting children, but also using DESCENDANTS for taking wider scope), where only one column is returned for accounts:
I've been googling for some time, but failed to find the solution so far. Thanks for any suggestions.
Hi @KMST ,
don't know if it's possible to achieve this with an adjusted MDX script.
But you can easily achieve the desired format by adding a column with this formula:
Record.FieldValues( Record.RemoveFields(_, {"[Measures].[Dummy]"}))
This returns a list with all non-Dummy-values that you can then expand vertically.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
102 | |
53 | |
21 | |
12 | |
12 |