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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
cwolff
Regular Visitor

Separating Data

I've started out using B.I recently and I'm having issues with a situation that happens often at my workplace.

 

I have a data set about constructions that often involves more than one city. As an example with random data:

 

RoadCityLength (miles)TypeCategoryValue ($)
John St.A10RoadWide1000
Mary St.B20InterstateWide2000
Tucson St.C/D40RoadNarrow4000

 

I have 3 roads I'm working on 4 different cities, since Tucson St. runs across two cities, so I've tried separating the data into:

 

RoadCityLength (miles)TypeCategoryValue ($)

John St.

A10RoadNarrow1000
Mary St.B20InterstateWide2000
Tucson St.C10RoadNarrow1000
Tucson St.D30RoadNarrow3000

 

I can do DISTINCTCOUNT in order to get the amount of Roads or Cities I'm working with to present my data and I can divide both my Length and Value between the cities, but I have a problem with other colums such as "Type" and "Category", of which I have several with lots of details. If I have any sort of visual that has those options, the total amount is higher than what it actually is. For this example, it'd say I have 3 Roads and 1 Interstate, when I'm only working with 2 Roads and 1 Interstate (same with 3 narrows vs. 2 narrows). How can I divide my data or maybe work on it in order not to count those again?

 

1 ACCEPTED SOLUTION
Fowmy
Super User
Super User

@cwolff 

You will have to add additional columns in the table to get distinct of those.

For Example:

 

Key = COMBINEVALUES("-",[Road], [City],[Type],[Category])

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

YouTube  LinkedIn





Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

4 REPLIES 4
Fowmy
Super User
Super User

@cwolff 

You will have to add additional columns in the table to get distinct of those.

For Example:

 

Key = COMBINEVALUES("-",[Road], [City],[Type],[Category])

________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

YouTube  LinkedIn





Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Sorry, I don't think I get it, isn't COMBINEVALUES only for measures? Also, should I add columns to my original table?

@cwolff 

You can add as a column in a table.

Example

Fowmy_0-1601323892316.png



________________________

If my answer was helpful, please consider Accept it as the solution to help the other members find it

Click on the Thumbs-Up icon if you like this reply 🙂

YouTube  LinkedIn

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Thank you very much, this was perfect!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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