cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
giost
New Member

How to persist #sections document introspection variable in Power BI

Hi,

I would like to setup a series of parameters so that I can access them easily set their values in the Power BI service (for e.g. PBI Version="1.0.0.0", PBI Envrionment="Test", PBI Author="XXX" etc.)

 

I would like to dynamically display both parameter names and parameter values into for e.g. a multirow card in a PBI Report.

 

Now I can easily see them into Power Query using the #sections[Section1] in a Query but it seems such values are not persisted when loaded into the Power BI (the table in PBI is empty, it just shows the schema but without any row).

 

Any idea how to achieve this?

2 REPLIES 2
Fowmy
Super User
Super User

@giost 

You can create a measure for each value PBI Version="1.0.0.0", PBI Envrionment="Test", PBI Author="XXX" etc and they will be available for you to show on any visual.

Not sure If I understand your question 🙂

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

@Fowmy : thank you for your reply but the use case here is different.

 

I have a shared dataset and I need to setup a dev/ops pipeline that moves this dataset from one workspace to the other with powershell injecting as a parameter the correct Environment Version etc. Such values must be seen within the report so that people using the dataset knows his version etc.

 

I want to create a dynamic solution: a parser in power query (M) that scan/enlist all the parameters present in the file (I don't know in principle how many they are or their names) and print out in the report a list/table with param names and param values.

 

The code is this one but the values you see in power query are not loaded to power bi and cannot use in any visual because like I understand the variable #sessions "lives" only within power query and become blank as soon as you import in power bi (i.e. you press close & apply in power query).

 

let    
    Source = Record.ToTable(#sections[Section1]),
    #"Filter Parameters" = Table.SelectRows(Source, each (Value.Is([Value], type text)))
in
    #"Filter Parameters"

 

Helpful resources

Announcements
PBI_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Kudoed Authors