Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Manage Parameter from Database


let Source = Xml.Tables(File.Contents("C:\temp\example.trx")), #"Filtered Rows" = Table.SelectRows(Source, each ([Name] = "Results")), Table = #"Filtered Rows"{0}[Table], #"Expanded Table" = Table.ExpandTableColumn(Table, "Table", {"Attribute:computerName", "Attribute:duration", "Attribute:endTime", "Attribute:executionId", "Attribute:outcome", "Attribute:startTime", "Attribute:testFile", "Attribute:testId", "Attribute:testListId", "Attribute:testName", "Attribute:testType"}, {"Table.Attribute:computerName", "Table.Attribute:duration", "Table.Attribute:endTime", "Table.Attribute:executionId", "Table.Attribute:outcome", "Table.Attribute:startTime", "Table.Attribute:testFile", "Table.Attribute:testId", "Table.Attribute:testListId", "Table.Attribute:testName", "Table.Attribute:testType"}) in #"Expanded Table"

I want to pass below value as variable from SQL database table:

"C:\temp\example.trx"
1 REPLY 1
ankitpatira
Community Champion
Community Champion

@Anonymous I have played with your situation for a while unfortunately i think you hit a roadblock at the moment as the approach i took was to create a query that connects to your sql server table and convert it to parameter. Then use that parameter to replace url string in power query however problem is currently on few queries (that returns a single number, text, scalar values) can be converted to parameters and not all. Therefore in this case query that will return your value from sql server table even if you do it as select 1 will be returned as table and therefore not able to convert it to parameter.

 

I have read somewhere that feature of converting query to parameter is going to grow with newer releases and i would suggest you wait until you're able to convert. Until then vote for this idea.

 

Hope it make sense.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.