Forum Discussion

nh27's avatar
nh27
Helper III
5 years ago
Solved

Removing rows with all null values

Hi All,

 

Currently building a model in Power BI and quite often with data refresh and new files we will have multiple rows where all values are blank but once in Power BI in the query editor they appear as null.

 

My question is, does anyone know of a formulae or a way to remove any rows where all values across that row are null?

  • Two options

    1. In Power Query, you apply a filter to the column so that it does not include nulls.
    2. Regardless of the column, you remove rows that are blank. Start menu. Remove Rows option, Remove Blank Rows option.

4 Replies

  • Two options

    1. In Power Query, you apply a filter to the column so that it does not include nulls.
    2. Regardless of the column, you remove rows that are blank. Start menu. Remove Rows option, Remove Blank Rows option.

  • v-yalanwu-msft's avatar
    v-yalanwu-msft
    Community Support

    Hi, nh27 ;

    You could remove empty in power query ,like below:

    The final output is shown below:


    Best Regards,
    Community Support Team_ Yalan Wu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • AndrewUrban's avatar
      AndrewUrban
      Frequent Visitor

      This little step just saved me hours of torment & heart ache. Thank you thank you thank you

       

  • nh27's avatar
    nh27
    Helper III

    Thank you all for your help, removing the blank rows worked, however needed to do this at an earlier step in my query editor for it to kick in. It did not seem to want to remove blanks after a number of applied steps for some reason.