2022-01-17

Conditionally remove row from table in Power Query or PostgreSQL

I have a list of employees and for some employees I have two rows when they changed from contract to permanent. I like to remove the row where the employee was a contracter.

employeeID EmployeeType Other Employee Data
216 contract drop this row
641 fulltime
216 fulltime
853 contract

I want to be the output

employeeID EmployeeType Other Employee Data
641 fulltime
216 fulltime
853 contract

Any suggestions how I can do this in Power Query (for testing) and / or PostgreSQL (final implementation) ?

EDIT: 2022/01/17

@ron-rosenfeld kindly provided the solution for Power Query below. I will try to summarize it here. Any inaccuracy is due to my lack of understanding.



from Recent Questions - Stack Overflow https://ift.tt/33alwg8
https://ift.tt/eA8V8J

No comments:

Post a Comment