Power BI Fixed Decimal has two digits, not four - powerbi

All documentations and tutorials out there mention that transforming a table column to Data Type 'Fixed Decimal' will make it have four digits to the right of the period symbol.
However, when I use this type, it only shows two and the Power Query for that step has:
= Table.TransformColumnTypes(myTable,{{"fieldName", Currency.Type}})
Was the default behaviour changed or do I need to first set some setting to get four? I tried this with multiple files.

Related

How do I convert a number from data type TEXT to whole number to further calculate it using DAX?

I am taking data from the excel where there is a column "Global" with values as whole numbers and decimal numbers. When I am importing it to Power BI, the column data type is coming as "TEXT" and hence I am unable to use it to calculate my new column which is "Local + Global / Total" since it cannot convert calculate on string which makes complete sense.
I looked it up and tried the following :
To change the column type to Whole Number / Decimal Number and it showed me an error that It cannot be converted.
I made a measure using the functions CONVERT and VALUE but in vain. It could not be converted saying a single value was expected but multiple values were provided in the latter.
How do I solve this?
EDIT
The column looks like this
Global
12345.67
43566
123.765
If it is showing error that It cannot be converted, obviously there are some garbage value in the column like - space, string or other values not a number. Please check your data first, hope you will get the issue as well.
In Power Query Editor You can select the column and change data type to Whole Number. In that case, some errors will be shown where the conversion failed to convert some value as shown below-
Here I have provided a string in the last row. Now you can check your data by filtering the column with error to check what are the actual values in the source. You can than perform some transformation to get the correct value value out of them.
You can also remove all records with error as shown below if you find those rows are with garbage value is not important for your.

Power BI - Extract / Moving value to a separate column

I have a column that includes 2 different values for more than 100k customers
The values are: "Consumer" , "SMB"
How can I move "SMB" values to a separate column ? I want each value to be shown in a different column so I can use KPI for each one of the values.
For ex: I want to create 2 different KPIs, one for SMB and 1 for Consumer, which show how money in total each segment has been charged.
When you load the data in the Power Query editor, use the command to split the column with the values. Use the comma as the delimiter.

Dax Related function returns all zero column

I have 2 tables which are related in a one-to-many fashion.
When I use related with string value columns as store name or even integer value columns it works fine and brings the correct value.
However when I try to bring the column I am interested in ("number of clients"), which is a numeric column, it only brings a column with 0 values.
I transform the column to string and even in that case it returns all 0 string value. Even if I concatenate the column with another string column like "store name", it will return the correct store name but with the number of clients transformed to zero.
I have compared the properties of the other numeric columns that work well with related and they seem to have the same settings. I have seen posts about people having trouble with related functions so I made a new report and imported the 2 tables again but the same thing happens.
Also when trying with lookupvalue I face the same issue.
please help!
Edit: here is an example of the situation with data
So in the background I have the table of the many side of the relation. I have added 2 columns, one in which the related function works, by bringing the client type data and the other one that doesn't work which should bring the number of clients data. ** the numbers of client type don't match in the shown tables because of the one to many relation.
In the front I placed a sample of the number of clients table where the client type and the number of clients are shown.
So both of the columns from client number table are numerical but somehow one column gets related correctly and the other one gets transformed to only zero values.

How can I cleanly order data in the desired sequence within Power BI Visualizations? (Line and Stacked Column Chart)

I am working on a report that displays monthly data most of which are represented in the following format, XX+YY (IE 01+11,02+10,03+09, etc.). The first set of digits reflect the represented month, so these naturally order themselves in sequence.
Image of visual with correct sequence
However, I must also include the financial plan for the year is in the format "FYXX Plan" where XX is the last two digits of the calendar year. When sorting text Power BI orders leading numbers before leading letters, so this moves the plan column to the END of the data set instead of where it logically belongs at the FRONT.
Image of visual with incorrect sequence
Is it possible to re-order my visual to still show the XX+YY monthly data in ascending order, but to move the FYXX Plan data to be the first column shown?
Very respectfully,
Jon J.
You could add a new column for sorting, stripping out the 'FY' when it exists e.g.
SortColumn = IFERROR(mid(Sorting[Date],find("FY",Sorting[Date])+2,10),Sorting[Date])
(For any value which includes 'FY' the mid function will show the remaining characters, if FY is not found it will error, and give the full date, there are a number of ways to achieve this using e.g. IF statements etc.
You can either replace the axis with this column, if you really need it to display as 'FYxx' you could set First(SortColumn) as the tooltip text to allow you to sort by that instead.

Power BI Desktop doesn't honor percentage column type

I've imported data (approximately 200 columns) into Power BI desktop (latest version as of 2017-08-02) and have explicitly told the app to treat a number of columns as being percentages. Within the query editor, I can verify that my values are treated as such:
When I put my data into a table, they show up as normal floats, not percentages. When I click on the exact same column as in the above picture and view it in the Modeling tab, Power BI shows it as being "General" format:
While I can go through and change the formatting here to have them all be percentages, I have already done so in the query editor! Is there a way to make PBI recognize my already specified format?
Short answer: No.
Explanation:
In the query editor, you didn't actually specify any format. What you specified is the data type, so that the source data can be read correctly. Say you have a column with data like 001, you can specify it as text type so you can retain the leading zero.
However, the actual formatting (i.e. data presentation) is done in your second step, because even if it's a (decimal) number, you can still format it as a percentage, with different decimal places, etc. (vice versa)