Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I'm hoping I'm just being dozy with this, but it's driving me crazy so any help would be much appreciated. Thank you.
I have a report which takes data from several tables, DimMonth, DimProduct, Sales, Stock, Forecast. The key driver is the month that's selected . So if I select last month, it will show me last month's sales, forecast, stock etc.
However if I select this month, we don't yet have any sales (as they haven't been processed yet as it's only the first of the month) and so the whole table is blank apart from the month column and product column (which come from dimension tables). If I create the same table, but leave off the sales column, then it works as expected for this month, but as soon as I add in Sales, it blanks everything else out.
How can I get it not to blank out the Stock and Forecasting values when there are no sales? I have selected the option to show items with no data.
The following shows what's happening.
1. Table works for last month
2. Table does not work for this month
3. Table works for this month if Sales column is removed
MONTH | PRODUCT | FORECAST | STOCK | SALES |
202310 | A | 1 | 2 | 3 |
202310 | B | 4 | 5 | 6 |
MONTH | PRODUCT | FORECAST | STOCK | SALES |
202311 | A | |||
202311 | B | |||
MONTH | PRODUCT | FORECAST | STOCK | |
202311 | A | 7 | 8 | |
202311 | B | 9 | 10 |
Thank you
Solved! Go to Solution.
@sg1234 , If you do not have data and still want to show the visual , you can create a measure with +0
example
Sales Measure = SUM(Sales[SalesAmount])+0
Or you can use the option, "Show items with no data" on fields
Thanks for your reply. Yes I have selected "Show Items With No Data" but it doens't solve my question. I was also hoping to do it without too many measures as I thought it might be quicker / more efficient and the data is right there and working for every other selected day! (But perhaps it's down to the efficiency of my measure coding!).
Do you know if there's anything else I can check / change before I resort to putting it in a measure?
I wonder if would it be more efficient to create a measure or to create a table containing the sumarised data at the level I need?
Many thanks again for your help. Sarah
THanks for your help. I have given up and written it as a measure as I couldn't get it to work any other way. Not quite what I wanted, but it'll do the job for now.
Many thanks @amitchandak for your help
@sg1234 , If you do not have data and still want to show the visual , you can create a measure with +0
example
Sales Measure = SUM(Sales[SalesAmount])+0
Or you can use the option, "Show items with no data" on fields
User | Count |
---|---|
76 | |
75 | |
46 | |
31 | |
27 |
User | Count |
---|---|
99 | |
91 | |
51 | |
49 | |
46 |