SQLTeam.com | Weblogs | Forums

Would like to write a query against one table which gives unique value from "pm_process_guid"


#1

I would like to write a query against one table which gives unique value from "pm_process_guid" for one ticket, along with all associated values in Assigned Group, Assigned User and Time on a column wise. Could one of you please help me out in how I should write a query in order to get a output like below?

pm_process_guid Assign Serial Number Assigned Group Assigned User Time
2E2A9A43-9607-4FCB-B3A7-550440823B20 1 APAC Ram 3/23/2016 15:06
2E2A9A43-9607-4FCB-B3A7-550440823B20 2 AM Raj 3/23/2016 15:06
2E2A9A43-9607-4FCB-B3A7-550440823B20 3 APAC Sree 3/23/2016 15:06

I‌ need to get an output like below,

pm_process_guid TotalAssign Count 1st Group 1st User Time 2nd Group 2nd User Time 3rd Group 3rd User Time
2E2A9A43-9607-4FCB-B3A7-550440823B20 3 APAC Ram 3/23/2016 15:06 AM Raj 3/23/2016 15:06 APAC Sree 3/23/2016 15:06
‌‌