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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
gitouttatown
Frequent Visitor

Connect to web data source like a folder?

I have some files published using apache and I am accessing them in Power BI with a Web connector. This works fine as long as I know the exact name of the file I want. But in some cases I need to import all the files in the web directory and don't know their names or how many there are.

E.g. my files are at  https://myserver/files/  and I am trying to access all the files in that web server directory in the same fashion as I coudl if using a FOLDER connnector, where I could read all the files in a Windows folder I can't seem to find any references to how to do this. I've see reference to accessing a SharePoint folder but this isn't SharePoint.

Any ideas?

6 REPLIES 6
efolly1
New Member

Hi everybody,

I'm not sure if this is the same issue that I have: I'm trying to use a function like "Folder.Files" to access a list of files that I have in my web server folder.

Do you have any idea?

All best.

Greg_Deckler
Super User
Super User

Not sure if there is a solution. You could just sync the files locally. Oh, yeah, Apache doesn't do that. 😉 Not easily I guess anyway. https://www.liquidweb.com/kb/how-to-sync-two-apache-web-servers/

 

@ImkeF any ideas here?

 

 


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Thanks, @Greg_Deckler  and @ImkeF however I don't need to sync multiple Apache servers. I have files being stored in one server and I can do a scheduled refresh with Power BI re-reading the data periodically.  My challenge is trying to find a way to treat that server directory as if it were a folder on a Windows OS, and have the functionality of a folder connection. That would allow me to get all the files in it, without knowing in advance how many there are, or their exact names. There may not be a way to do it like that.

Hi Gitouttatown,

 

Have you found the solution? I have the same problem getting all files in our server folder. Thank you.

 

 

Grace Zhang

Hi Grace- sorry for the very delayed reply. I didn't find a solution in the way I hoped. Ultimately I solved the problem by algorithmically generating all the file names I expected I might find, and then querying for each and doing error handling for items not found. That is, I'm looking for files that will be generated each day with a predictable pattern based on the date it was generated. So I look for each specific file. It's more work, but it does what I need. I would still like to be able to get a list of all files that are actually in a folder on a web server but I didn't find that sort of soltuion.

Hi @gitouttatown ,

I'm not familiar with it, sorry.

 

Imke Feldmann (The BIccountant)

If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!

How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors
Top Kudoed Authors