Get the distinct rows in an Excel table based on the latest modifiedDate -


following table have in excel. contains duplicate entries of tickets. need convert excel table table having unique rows having latest modified_date

tket status modified_date ---- ------ ------------- 5184 active 20-07-2015 5184 active 22-07-2015 5184 closed 25-07-2015 5292 active 22-07-2015 5292 closed 23-07-2015 5480 active 23-07-2015 5480 closed 24-07-2015 

do need write macro code achieve same or there other alternate in ms excel. using office 2013.

it 2 simple step solution. (tried use concept of sql group-by clause)

step 1: sort entire range on

  • ticket id asc
  • modified date desc

then in new column besides modifieddate use below formula

=if(a2 = a1,"","1")   ticket  status  modified    uniquerows 5184    closed  25-07-2015  1 5184    active  20-07-2015 5184    active  20-07-2015 5292    closed  23-07-2015  1 5292    active  22-07-2015 5480    closed  24-07-2015  1 5480    active  23-07-2015 

my table starts @ a1 cell.

since, after sorting have tickets together, form group. within group sorted on modified date in descending order. have latest record on top ticket group.

i know latest record (within group) on top, thus, compared current ticket id 1 above, if changes new group , output value 1.

now filter '1' , have records of interest.

ticket  status  modified    uniquerows 5184    closed  25-07-2015  1 5292    closed  23-07-2015  1 5480    closed  24-07-2015  1 

Comments

Popular posts from this blog

yii2 - Yii 2 Running a Cron in the basic template -

asp.net - 'System.Web.HttpContext' does not contain a definition for 'GetOwinContext' Mystery -

php - How do you embed a video into a custom theme on WordPress? -