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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
ValeriaBreve
Post Patron
Post Patron

Looping through folder files

Hello,

I am looking for guidance here...

I have a folder with actual and forecast data files, for the same products, each one containing the same columns but one will be stamped Aug, the other one Sept, etc with revised actual/forecast figures.

ValeriaBreve_0-1665755223627.png

 

I need establish forecast accuracy and stability, so read the same forecast (e.g. Product A for Jan 2023) on every file and compare them. (n, n-1, n-2, n-3, etc)

 

Now, from PowerQuery I am able to get to the folder, rank the files, but then? What's best? Is it OK to have 1 query per file with the related file creation date and then make the relationships in the report? Or is there another way of handling this type of situation?

 

Thanks a lot!

Kind regards

Valeria 

 

1 ACCEPTED SOLUTION
ImkeF
Super User
Super User

Hi @ValeriaBreve ,
you should keep them in one query and use the Index column in your DAX measures to distinguish between them. 
Use the Combine Binaries method to create the consolidated query: New Combine Binaries Experience - Excelguru

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

View solution in original post

3 REPLIES 3
ImkeF
Super User
Super User

You are welcome @ValeriaBreve  🙂

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

ValeriaBreve
Post Patron
Post Patron

Thank you so much Imke!!!!!!! It is the first time I have this type of data, I was more used to production data, so thanks for pointing me to the right direction! 

ImkeF
Super User
Super User

Hi @ValeriaBreve ,
you should keep them in one query and use the Index column in your DAX measures to distinguish between them. 
Use the Combine Binaries method to create the consolidated query: New Combine Binaries Experience - Excelguru

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
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors
Top Kudoed Authors