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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
new2pbix
Frequent Visitor

limiting/consolidating datasource in chart

appologies in advance for not really knowing how to articulate what im trying to accomplish.

Im pointing PowerBI to a folder to get aggregate csv source for trends... Ive successfully built a line graph showing count of work orders open per month historically over the last 12 months. I use the datasource folder and the collection of csvs in the folder for multiple different reports (different reporting cadence). since jan 1, i drop in a new csv weekly, but the previous months there is only one monthly csv. so when i chart over time, i have one data point per month for jan 21-dec 21, but after jan 1 22, i have 4 data points per month. as i move forward, i will continue to have weekly csvs in that folder, and im unable to get historical data to fill the gaps in the 2021 months. so when i chart my totals, i have data points per month everywhere along the X-axis where there is a report. 

My question is, is there a way to automatically have powerBI only look at one csv file per month for jan 22 and feb 22, etc moving forward? eventually i will have enough weekly reports that historically the single data point months will fall off the left side.   When filter out 2022, and show only the months where i have a single data point per month, i get exactly the look I want.

If i switch to a vertical bar graph, i have tiny toothpick size bars with a half mile gap between months, and in 2022, i have the 4 data points. filtering out 2022, my bars are normal and viewable.

I am not on my work computer so i cannot provide screen shots. maybe i can edit and add later if ive completely lost you.

TL;dr: Is there a way to automatically combine or filter multiple csv datasource files in a folder in a month so that i only report counts once per month in a line chart instead of all weekly data points per month? I could filter them manually but i dont want that visible to the end user... and i use the same datasource to provide other weekly reports so they need to remain in the datasource folder. thanks in advance. this is a lot to process.

2 REPLIES 2
Greg_Deckler
Super User
Super User

@new2pbix I'm with @parry2k, very hard to follow. Perhaps modify your query to preserve the file name and then you can use that as a filter?


Follow on LinkedIn
@ 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...
parry2k
Super User
Super User

@new2pbix very hard to understand, having some sample data and the screenshots will help. As far as it looks, it has nothing to do with the CSV file but how you want to present the data, but again, a bit hard to provide an answer without looking at the details.



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.

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

July Newsletter

Fabric Community Update - July 2024

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