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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
ashmitp869
Post Patron
Post Patron

filter from a sharepoint folder - power query

Hi,

 

How can filter from a sharepoint folder with file name 

Course439.csv

Course196.csv

Course111.csv

Courseany3digit.csv

 

ashmitp869_0-1741735726076.png
Thanks

 

5 REPLIES 5
kushanNa
Advocate I
Advocate I

HI,

use the following filter 

 

 

 

= Table.SelectRows(#"Changed Type", each  
    Text.StartsWith([Name], "Course") and  
    Text.EndsWith([Name], ".csv") and  
    Text.Length([Name]) >= 8 and  
    List.Contains({"0".."9"}, Text.Middle([Name], 6, 1)))

 

 

Before Filter

kushanNa_1-1741750635167.png

 

 

after filter

kushanNa_0-1741750609223.png

 

 

 

parry2k
Super User
Super User

@ashmitp869 click the filter (down arrow) and use text filter -> begins wtih

 

parry2k_0-1741745074369.png

 

k on the filter and then use start withs



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

That's not possible as I have a file name CourseList which I don't want to pick

ashmitp869_0-1741747197714.png

 

parry2k
Super User
Super User

@ashmitp869 is this a fixed value for the names or based on some logic?



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

No its not fixed.

 

Is can be CourseXXX.csv
XXX can be any three digit (random)

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!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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