Forum Discussion

NathanUMB's avatar
NathanUMB
New Member
5 years ago
Solved

Remove Text in Integer Column

So as part of one of my trainings I am pulling the data from this website url.

https://www.california-demographics.com/cities_by_population

However there is new issues from the data pull.

The Rank column now on some rows has the rank number and then the word "TIE" 

Plus if you view the source you will see there are some other html chars in it.

 

I am new to Power BI and I figure this is easy to do but after searching on Google and not figuring out the answer I found this Forum and figured I would ask.

 

Thanks for any help,

Nathan

  • Hi NathanUMB 

    Please follow these steps:

    Open Power Query

    Select Rank and change its type to text

    You will see TIE for some cells, Select and right click on Rank Column

    Click on Replace Values and 

     

    Leave "Replace With" Blank and click OK

    Finaly re change the type of the Coloumn to Whole Number

    Voilà

     

    If you wanted to keep the TIE in the Rank column then skip the 2 last steps and keep the column as TEXT format

     

     

     

     

3 Replies

  • aj1973's avatar
    aj1973
    Community Champion

    Hi NathanUMB 

    Please follow these steps:

    Open Power Query

    Select Rank and change its type to text

    You will see TIE for some cells, Select and right click on Rank Column

    Click on Replace Values and 

     

    Leave "Replace With" Blank and click OK

    Finaly re change the type of the Coloumn to Whole Number

    Voilà

     

    If you wanted to keep the TIE in the Rank column then skip the 2 last steps and keep the column as TEXT format

     

     

     

     

    • NathanUMB's avatar
      NathanUMB
      New Member

      Thanks I knew it was something simple.  Just was not sure how to search to find it. Just trying to get through some training.  I simply added those steps in the transformation on the pull form the url.

       

      Thanks again.

  • HI NathanUMB ,

     

    Can you share some screenshot aroung the sample data that you are pulling?

    Also a screenshot on what different values the RANK column has?

     

    Thanks,

    Pragati