The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I have the table below, and when I select line 2 on table visual, I want to generate a series of numbers from 100 to 105. I've seen a similar question, but I want to generate the series according the selected value. If I select more than one row it shoud generate the series only for the selected rows.
group | from | to |
group1 | 2 | 3 |
group1 | 100 | 105 |
group2 | 15 | 20 |
group2 | 1000 | 1013 |
expected result
group | number |
group1 | 100 |
group1 | 101 |
group1 | 102 |
group1 | 103 |
group1 | 104 |
group1 | 105 |
Is it possible?
Solved! Go to Solution.
@dosc_21 , A slicer value can not control new table generation. So if you need a table you best bet is
generate(Table, generateseries([from],[to]))
If now then you have create a measure with help from an independent table
Series = generateseries(Min(table[From]), Max(Table[to]))
Then create a measure and use that along with Series value column
Sumx(filter(Table, Table[from] <= Max(Series [Value]) && Table[to] >= Max(Series [Value]) ), Table[Group])
use this measure with the value column from the series table
very similar to
Power BI Dax Measure- Allocate data between Range: https://youtu.be/O653vwLTUzM
@dosc_21 , A slicer value can not control new table generation. So if you need a table you best bet is
generate(Table, generateseries([from],[to]))
If now then you have create a measure with help from an independent table
Series = generateseries(Min(table[From]), Max(Table[to]))
Then create a measure and use that along with Series value column
Sumx(filter(Table, Table[from] <= Max(Series [Value]) && Table[to] >= Max(Series [Value]) ), Table[Group])
use this measure with the value column from the series table
very similar to
Power BI Dax Measure- Allocate data between Range: https://youtu.be/O653vwLTUzM