Forum Discussion

dbrandone's avatar
dbrandone
Helper IV
5 years ago
Solved

Issues with changing column data type

Hello All,

 

I am adding data to my one of my workspaces and I am currently in the transform process before applying. I noticed that a few number columns were marked as text and I will need to perform some calculations based on these two columns. The numbers in the columns need 2 decimal places. The number are currently either in whole number form (2), in one decimal place form (2.5), or 2 decimal place form (2.75), depending on the value. When I change the data type to decimal number, the 2 decimal place number get rounded up. When I choose fixed decimal place, some of the values become null. I have been able to delete the step and try again and sometimes I can get the system to work with the decimal number option, but when I then go to change the data type of the second column, the numbers for the 1st column will change.

 

Any idea what may be causing this or a fix for this problem. Any help is appreciated. Thanks

  • Hi dbrandone,

     

    This sometimes happens when you change the data type in a field.

    You can change data type in Query Editor and then refresh data in power bi desktop.

    If you still have some question, please don't hesitate to let me known.‌‌

     

    Best Regards,

    Link

     

    Is that the answer you're looking for? If this post helps, then please consider Accept it as the solution. Really appreciate!

2 Replies

  • dbrandone really confusing what is happening? Can you pate M code by clicking on Advanced Editor? What is your data source?

  • v-xulin-mstf's avatar
    v-xulin-mstf
    Community Support

    Hi dbrandone,

     

    This sometimes happens when you change the data type in a field.

    You can change data type in Query Editor and then refresh data in power bi desktop.

    If you still have some question, please don't hesitate to let me known.‌‌

     

    Best Regards,

    Link

     

    Is that the answer you're looking for? If this post helps, then please consider Accept it as the solution. Really appreciate!