Forum Discussion
Power BI doesn't use decimals
- 10 years ago
Never mind,
In the edit query I found that in the "applied steps" window i made 2 (historic) alterations for the data, first I made it a "whole numer" then a couple steps later a "decimal"....deleted the first step and the data came through ok.Solved, -1 kudo for meself!
thanx for the input though!
The steps you can take to make sure your values stay the same as you want them to be in the excel file are:
Go to Home > Edit Queries > Edit Queries . Once you are in the Power Query Editor, check the Query Settings on the right side and look at the Applied Steps. You will see the first step being Source, after which you will have Navigation and etc.. If you have data which you have to remove (ex. First 2-3 rows, and then promote the first row - Use first row as Header, what will happen next is that Power Bi will take Change the type of the columns based on what it finds in the first 200 rows in each column. If you have 0's witout them having decimal numbers in the first 200 rows, then Power Bi will decide that the data type for that column is Whole number. Unfortunately when you change it manually from Whole Number to Decimal Number, that does not always have an effect on the outcome. Therefore what you can do is go to: Applied steps, find Changed Type and DELETE it from the applied steps. Once this is done go to Transform in Power Query Editor and Power Bi will no longer Detect the data type on it's own, and it will show Data Type: Any. When you see Data Type Any, just select the columns you need and change the data type from Any to Decimal points. Click close and Apply and that should do it.