Hello ,
Welcome to the Q&A .
Your goal is to get the latest data , I think you can use the max aggregate function and the belwo query should be helpful . I have not tested the query but it should give you the idea . In case if you ran into issue , please do let us know .
SELECT
Job, Ref, Location, Queue, Description, Status, ElapTime, max(cast (Time as datetime)) as Time
INTO
output_source
FROM
input_source
GROUP BY Job, Ref, Location, Queue, Description, Status, ElapTime
Thanks & stay safe
Himanshu
Please do consider to click on "Accept Answer" and "Up-vote" on the post that helps you, as it can be beneficial to other community members