Repeating countries in the power bi location filter - location

I am working on a project for developing dashboard. The dataset I am using has fields area, country, region, sub region. For many records, country, region and sub region has the same value as that of country. When I show this as visualization (hierarchical geography filter:having area,country,region and sub region within each other) on my Power Bi page, the countries are repeating within each other. How can I resolve this? Any help is appreciated. Additionally, my apologies, if any such question is already raised and I have mistakenly overlooked it. TIA

You can set Latitude and Longitude value in your dataset for each specific area.

Related

Excluding a Metric from a Visualisation Filter

I am a new user to MicroStrategy Developer and am stuck with a task that I want to do. I have created a table visualisation and applied two filters to the visualisation via the visualisation filters:
Top 10 Rank by Volume Filter
A current month Filter
My table has the following table headings:
Region
Sales Person Name
Sales Volume
Average Sales Volume To Date
I want the table to display the Current Months values for the 1st three columns and then the last column to display the average sales volume to date (based on 2 years worth of data). However clearly Average Sales Volume is not working correctly, I am assuming this is due to the Month filter applied to the visualisation.
Being a new user to MicroStrategy, I am not sure how best to get round this? Is there a way of making the Average Sales Volume To Date metric independent of the Date filter applied to the visualisation? Or a better way to build this without applying visualisation filters?
Any hints or tips would be much appreciated.
Thanks!
I am not very sure whether this works out but you can give it a try.
Create the "Average Sales Volume To Date" metric as a level metric and set the filtering as Ignore.

Swapping rows and columns in a matrix in Power BI

I want to analyse the sales of a certain company in Power Bi. I have a customer dataset with nine columns (gender, city, age range, hair colour etc.) and one million records. Now I want to put those columns in a matrix. For instance:
Rows: Gender
Columns: Age Range (<16, 17-20, 21-25 etc.)
Values: Number of Sales
I present this dashboard towards some people and I want to 'play' with the data. What happens if I change the rows to 'hair colour' for instance. Is there a way to do this without using bookmarks? In one sentence: swapping rows and columns of a matrix while you present the dashboard and cannot use the option 'Fields'? Or at least point me in the right direction? It would really help me. Thanks in advance!
Unfortunately, the quickest way to do this is using the Fields pane. The only other option that is available would be Bookmarks, but I guess you have already tried that. I guess you are an option similar to the one available in "Pivot Charts" where you can "Switch Rows/Columns" with the click of a button. That option is not available in Power BI at this point, as far as I know.

Duplicate key measure columns appearing in a matrix

The requirement:
My users want a slicer which displays the dimensions of a data table they can then select from and have the dimensions display in a corresponding matrix visual along with two measures, Sales TY and Sales LY.
Progress so far.
I’ve achieved this by taking the table, selecting the column which indexes the table and unpivoting the rest of the columns. Next I place a slicer on the report and attach it to the unpivoted table’s Attributes field (now renamed as ‘Column’). Finally, I add a matrix visual to the report and add to it the unpivoted table fields Column, Index and Value fields. Now when I click on the slicer, whichever dimensions I select appear in the matrix.
The problem:
However, when adding the measures previously created (Sales TY and Sales LY) to the matrix, each measure is repeated after every column selected for display, whereas I only want the measures to display once.
Does anyone know if this possible? I’ve tried a number of approaches but nothing seems to work. I’m a new user so apologies if this is an FAQ I’ve yet to come across or I’m doing something glaringly obviously wrong. As I say I’m only just starting out in DAX and Power BI. I’m looking pretty hard at table functions and the Switch statement with the hope of calculating the solution somehow but haven’t managed it yet. Any advice, steer or comment greatly appreciated, thanks.

DAX COUNT/COUNTA functions

I've looked at many threads regarding COUNT and COUNTA, but I can't seem to figure out how to use it correctly.
I am new to DAX and am learning my way around. I have attempted to look this up and have gotten a little ways to where I need to be but not exactly. I think I am confused about how to apply a filter.
Here's the situation:
Four separate queries used to generate the data in the report; but only need to use two for the DAX function (Products and Display).
I have three columns I need to filter by, as follows:
Customer (Display or Products query; can do either)
Brand (Products query)
Location (Display query)
I want to count the columns based on if the data is unique.
Here's an example:
Customer: Big Box Buy;
Item: Lego Big Blocks;
Brand: Lego;
Location: Toys;
BREAK
Customer: Big Box Buy;
Item: Lego Star Wars;
Brand: Lego;
Location: Toys;
BREAK
Customer: Big Box Buy;
Item: Surface Pro;
Brand: Microsoft;
Location: Electronics;
BREAK
Customer: Little Shop on the Corner;
Item: Red Bicycle;
Brand: Trek;
Location: Racks;
In this example, no matter the fact that the items are different, we want to look at just the customer, the brand, and the location. We see in the first two records, the customer is "Big Box Buy" and the brand is "Lego" and the location is "Toys". This appears twice, but I want to count it distinct as "1". The next "Big Box Buy" store has the brand "Microsoft" and the location is "Electronics". It appears once and only once, and thus the distinct count is "1" anyway. This means that there are two separate entries for "Big Box Buy", both with a count of 1. And lastly there is "Little Shop on the Corner" which appears just once and is counted just once.
The "skeleton" of the code I have is basically just to see if I can get a count to work at all, which I can. It's the FILTER that I think is the problem (not used in the below example) judging by other threads I've read.
TotalDisplays = CALCULATE(COUNTA(products[Brand]))
Obviously I can't just count the amount of times a brand appears as that would give me duplicates. I need it unique based on if the following conditions are met:
Customer must be the same
Brand must be the same
Location must be the same
If so, we distinctly count it as one.
I know I ranted a bit and may seem to have gone in circles, but I was trying to figure out how to explain it. Please let me know if I need to edit this post or post clarification.
Many thanks in advance as I go through my journey with DAX!
I believe I have the answer. I used a NATURALINNERJOIN in DAX to create a new, merged table since I needed to reference all values in the same query (couldn't figure out how to do it otherwise). I also created an "unique identity" calculated column that combined data from multiple rows, but was hidden behind the scenes (not actually displayed on the report) so I could then take a measure of the unique values that way.
TotalDisplays = COUNTROWS(DISTINCT('GD-DP-Merge'[DisplayCountCalcCol]))
My calculated column is as follows:
DisplayCountCalcCol = 'GD-DP-Merge'[CustID] & 'GD-DP-Merge'[Brand] & 'GD-DP-Merge'[Location] & 'GD-DP-Merge'[Order#]
So the measure TotalDisplays now reports back the distinct count of rows based on the unique value of the customer ID, the brand, and the location of the item. I also threw in an order number just in case.
Thanks!
I am semi new to DAX and was struggling with Count and CountA formula, you post has helped me with answers. I would like to add the solution which i got for my query: Wanted count for Right Time start Achieved hence if anyone is looking for this kind of answer use below, filter will be selecting the table and adding string which you want to
RTSA:=calculate(COUNTA([RTS]),VEO_Daily_Services[RTS]="RTSA")

Telerik Report omitting data

After performing a product evaluation by one of the managers other can change the scoring for certain categories. This changes in scoring are stored in the database for reference.
The structure of the evaluation is like this:
Evaluatoin
- Category
- Scoring point
an evaluation can have many categories which all can have many scoring points.
My problem is the following:
If I change a scoring point a few times all is entered in the database but in the reports i am only seeing the first scoring point. The rest of them with the same name are left blank but are using space just as it would if all were visible. The stored procedure that is delivering the data is working fine. It bring all data to the report which then displayes it wrong.
=Fields.CategoryName is working fine... every category name is displayed correctly
=Fields.ScoringPointName is not working... it displayes only the first and leavese all the rest blank... if for example a scoring point name is Product robustnes it would display only the first change of scoring but wouldnt display the rest
Any ideas???
Found out what the problem was. Maybe it will be helpful for other people
I was showing the data in a group header section with grouping =Fields.DefinitionText. Thus it will only repeat if the Fields.DefinitionText is distinct. About the empty space it's caused by the detail section that repeats for every data record. Thus if I want to display all of the data records I have to move the group header section textboxes to the report's detail section.
Here and Here are some usefull things about reporting.
Cheers

Resources