Forum Discussion

cham's avatar
cham
Post Patron
7 years ago
Solved

Remove rows

Hi,

 

I'm having data set includes call details. Some calls are replace by other users. So one call can be replace by many users. But i want to get the terminated user details because he is the perosn who resposible for that call.

 

So, I want to delete replaced value and only need to show terminated person details, How can i Do  that?

Please check the below table. I want to remove the highlighted rows.

 

DateCaller IDDestinationStatusRingingTalkingTotalsCostReason
1/12/2018Marry98728892answered0:00:000:00:08  Mary replaced by
 Jack99982725answered0:00:000:00:17  Mary replaced by Jack
 Peter92882882answered0:00:040:01:50  Jack replaced by Peter
 Jude82272882answered0:00:040:00:11  Jude was joined
 Rose82727822answered0:00:000:03:430:06:173.9Terminated by Rose
1/12/2018Chan83773883answered0:00:040:01:500:06:173.9Terminated by Chan
  • Anonymous's avatar
    Anonymous
    7 years ago

    Add a conditional column to filter out the "replaced" value rows with blanks. Then, remove the blank rows.

     

     

    Then in modelling tab, simply filter the blank rows or generate the following Power query code:

     

    = Table.SelectRows(#"Changed Type", each [Custom] <> Blank())

     

    Please accept the solution if I answered your query.

4 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Add a conditional column to filter out the "replaced" value rows with blanks. Then, remove the blank rows.

     

     

    Then in modelling tab, simply filter the blank rows or generate the following Power query code:

     

    = Table.SelectRows(#"Changed Type", each [Custom] <> Blank())

     

    Please accept the solution if I answered your query.

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

    Hi cham 

    Does the last column "Reason" exsit in your dataset?

    or is it written by you here to illustrate the case?

     

    If the last column "Reason" doesn't exsit in your dataset, how do i find which rows need to be deleted?

     

    Best Regards

    Maggie

    • cham's avatar
      cham
      Post Patron

      Hi Maggie,

       

      Reason column is exist in my dataset.

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

    Hi cham 

    Does sbelanix 's suggestion really help you?

    If it does, could you kindly accept it as a solution so others may benefit from it.

    If not, please let me know.

     

    Best Regards

    Maggie