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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
andi2333
Helper I
Helper I

Need help for a simple try otherwise query

Hello, I am pretty new to powerBI and this forum and I am seeking help for a seemingly easy case.

 

I am trying to load data from multiple excel sheets which are all in a folder. Each sheet has multiple tabs with changing names. I only need data from one tab from each file.

 

I was trying to handle this with the following statement, but now I have problems with the syntax for the 2nd error case....basically I am trying to create a nested try-otherwise statement, but I am not sure if such a thing even exists.

 

 

#"Order List_Sheet" = try Source{[Item="Order List",Kind="Sheet"]}[Data] otherwise Source{[Item="OrderList",Kind="Sheet"]}[Data] otherwise Source{[Item="Order list",Kind="Sheet"]}[Data],

 

 

Any help on this is much appreciated.

 

Thanks

 

1 ACCEPTED SOLUTION
AndrewPF
Helper V
Helper V

I think you may need another "try": 

#"Order List_Sheet" = try Source{[Item="Order List",Kind="Sheet"]}[Data] otherwise try Source{[Item="OrderList",Kind="Sheet"]}[Data] otherwise Source{[Item="Order list",Kind="Sheet"]}[Data],

View solution in original post

1 REPLY 1
AndrewPF
Helper V
Helper V

I think you may need another "try": 

#"Order List_Sheet" = try Source{[Item="Order List",Kind="Sheet"]}[Data] otherwise try Source{[Item="OrderList",Kind="Sheet"]}[Data] otherwise Source{[Item="Order list",Kind="Sheet"]}[Data],

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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