Is there such a thing? I've looked through the msft library with no luck (also via "=#shared" in PQ)
I need a dynamic and automated way to generate this list to pass off as a parameter to another function.
Let me know if you have any suggestions.
Solved! Go to Solution.
Oustanding Maxim; pretty sure this will do!
I am wanting to create a query that will automatically scan through (any) model tables/queries, ID "date" / "datetime" fields, determine MIN and MAX values and then feed those as parameter inputs into a query function that generates a dimCalendar table (FNdimCalendar) automatically. Step one is to ID the tables which can then be passed off to something like Table.Schema function etc. You just paved the initial portion of the path.
1) your comment to "Beware of recursion" - can you please elaborate?
2) Are you aware of any command etc. that would allow the query grouping structure to be accessed as well? Below excerpts are those of a poor example (essentially testing model) - I am referring to "Sources" and "Other Queries".
Thank you again for the input!
1) That is precisely what I had in mind. I am not seeing why it should be tricky but let me dig into it and I am sure I will find something else to quiz you on 🙂
2) 10-4. As part of my research, I reached out to some Microsoft engineers via email. Should I actually get a reply, I will be sure to ask this questions as well and will let you know what they say.
Awesome question, and I think I have a solution to only keeping the tables. Essentially, a try statement that attempts to count the number of columns in a table (all tables will have at least 0). -1 is thrown in case of an error. Then just keep the rows with a value >-1
let Source = #sections, Section1 = Source[Section1], #"Converted to Table" = Record.ToTable(Section1), #"Add TableTest" = Table.AddColumn(#"Converted to Table", "TableTest", each try Table.ColumnCount([Value]) otherwise -1, Int64.Type), #"Filtered Rows" = Table.SelectRows(#"Add TableTest", each [TableTest] > -1) in #"Filtered Rows"
Visit our Community Blog for articles, guides, and information created by fellow community members.
Need help with the Power BI Community? Our 'Using the Community' support articles are a great place to start.
Looking for inspiration on how to present your data? Need instructional videos? Check out our Galleries!
Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications