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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Winnie2024
New Member

Dynamic source data for dataflow

In my case, I want to load data into Fabric data flow.Suppose the dynamic table name can be get from one metadata table.  Here is my  M language code:
 
--First get the table name 
Source = Lakehouse.Contents([]),
#"Navigation 1" = Source{[workspaceId = "12333r3r"]}[Data],
#"Navigation 2" = #"Navigation 1"{[lakehouseId = "aaefefe"]}[Data],
my_table_name = #"Navigation 2"{[Id = "est", ItemKind = "Table"]}[Data],
 
---Then get the data from the table name above
#"Navigation 4" = Source{[workspaceId = "6d9a79dc-e9bc-42f8-958b-e5e896744437"]}[Data],
#"Navigation 5" = #"Navigation 1"{[lakehouseId = "aa6082ce-3048-4bc0-aa16-80e06a37697d"]}[Data],
#"Navigation 6" = #"Navigation 2"{[Id =my_table_name , ItemKind = "Table"]}[Data]
in
#"Navigation 6"
 
 
But i got error:
 Screenshot 2024-03-29 at 17.54.53.png
 
Any idea? 
Thanks.
1 ACCEPTED SOLUTION

It worked. Thanks you for your help.

View solution in original post

4 REPLIES 4
miguel
Community Admin
Community Admin

Could you please share the full query that you have for your "get table name" query? It should yield a single scalar value. Basically a text string. If it doesn't, that's what's causing the issue in the subsequent query.

It worked. Thanks you for your help.

Hi @Winnie2024 


We haven’t heard from you on the last response and was just checking back to see if you have a resolution yet.
In case if you have any resolution please do share that same with the community as it can be helpful to others.
Otherwise, will respond back with the more details and we will try to help.


Thank you.

v-cboorla-msft
Community Support
Community Support

Hi @Winnie2024 

 

Thanks for using Microsoft Fabric Community.

Apologies for the inconvenience.

 

If you get an Expression.Error: The key didn’t match any rows in the table in Power BI, it means that you’ve made some changes to your source file and haven’t updated them in the Power Query. 

In most cases, the error arises when the Sheet’s Name is not the same on your original and destination file.

 

For more details please refer : How to Fix “The Key Didn’t Match Any Rows in the Table”.

 

I hope this information helps. Please do let us know if you have any further questions.

 

Thanks.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.

Top Solution Authors