Search code examples
powerbipowerquerypowerbi-desktoppowerbi-datasource

In Power BI, how to remove rows having names starting with 'NewHire' & count remaining employees?


My table looks like this example:

enter image description here

I want to remove all rows which start with 'NewHire' as name and calculate the number of employees remaining. The list will have more NewHires added later, hence I want to write a code to automate the process in Power BI.

Please help me.

Thanks & Regards.


Solution

  • You can do it in Power Query Editor. Go to the table and select your column. From top right corner drop down, select Text Filter and the select Does not begin with... and put NewHire in the respected filtering text box.

    Follow this below image as a reference.

    enter image description here