Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Import number w/ decimal position from MySQL db

I am trying to import data with decimal positions from MySQL DB , my data looks like this in my database:

 

637272.88842

28642.0398

7255384.8920

 

But when I import the data in Power BI I can't get the decimals, and the numbers look like this:

637272.000

28642.000

7255384.000

 

I have already changed the data type format to decimals. I tried to do changes from Power Query and Power BI Desktop, but I can't fix the problem. How can I change my data type and get those decimals? I don't need all the decimals either, just the first two would be enough.

  • Hi Anonymous 

     

    When you import the data from MySQL DB, is there a Change Type step in Applied Steps pane in Power Query Editor? If there is, you could remove this auto-generated step and change the data type of each column per your need. After you remove this step, does this column show the decimals correctly?

     

    Regards,
    Community Support Team _ Jing
    If this post helps, please Accept it as the solution to help other members find it.

4 Replies

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks for your answer and the link to the video.

  • v-jingzhang's avatar
    v-jingzhang
    Community Support

    Hi Anonymous 

     

    When you import the data from MySQL DB, is there a Change Type step in Applied Steps pane in Power Query Editor? If there is, you could remove this auto-generated step and change the data type of each column per your need. After you remove this step, does this column show the decimals correctly?

     

    Regards,
    Community Support Team _ Jing
    If this post helps, please Accept it as the solution to help other members find it.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks! That was very helpful!