How can we write the query for getting a set of rows where it was last updated grouped by a field name . Example
no – siteid – status – created_at
the ‘no’ number increases continuously as its the status report provided from another source. As in , Insertion happens 24/7 at some interval. But i want to check the status of 10 sites at the second i run the query .
There are only 10 sites . and i want to generate the report of the status of these 10
as in the last inserted query will give us the current status of the site.
I tried this
SELECT created_at,siteid FROM [TOC].[dbo].[frame1] GROUP BY siteid ORDER BY created_at DESC
But no luck
I’m not actually sure what you want, can you give example input and output data?
For now here is something that might be useful to you…