Forum Discussion
Using a table visual, splitting the results into 2 columns
lc_financeI followed the steps now, and the list of report names changed, but the reports are still split unevenly. The split needs to happen after the slicer labeled D&M, TS, WS, and WL are applied.
The report names are not split evenly.
Hi Anonymous ,
in that case, you can create a calculated measure instead of a calculated column.
Calculated measure take into account any filter that you apply to your Power BI.
You can use a slightly different DAX formula for the calculated measure:
Column number =
VAR numberOfRows = COUNTROWS('Text')
VAR currentIndex = SELECTEDVALUE('Text'[Index])
RETURN IF (currentIndex<=numberOfRows/2 , 1,2)
Does this help you?
LC
Interested in Power BI and DAX templates? Check out my blog at www.finance-bi.com
- Anonymous6 years agoNot applicable
lc_finance I added the quick measure, but the report names I have are all valued at 2 now. When changing the filter to 'is 1' nothing appears, but 'is 2' produces all the reports.
Below is how I adapted your example to my data, if that helps.
Column number2 = VAR numberOfRows = COUNTROWS('master') VAR currentIndex = SELECTEDVALUE('master'[Index.1]) RETURN IF (currentIndex<=numberOfRows/2 , 1,2)- lc_finance6 years agoSolution Sage
Hi Anonymous ,
could you share an example of your Power BI file?
That would help me to better understand the issue. You can upload it to a service like One Drive, Google Drive, Dropbox and then share the link.
Regards,
LC
- Anonymous6 years agoNot applicable
lc_finance I am not able to due to the sensativity of the data. However, I think what I need is a calculated measure.
To recap, I have two slicers that filtered down a list of report names into a matrix. A second matrix is being added, and the filtered report names need to be split so that one half is in matrix one, and one half in matrix two. I don't think the correct solution is to split the underlying data but instead to have the result of the two slicers split. Would you agree?