Home > database > Handsome little brothers, encounter a problem of data query, consult everybody brethren
Handsome little brothers, encounter a problem of data query, consult everybody brethren
Time:09-29
Dear little brother, How to implement the data search: Different Object query the last N days data, Data structure of the diagram below, keep yellow data
Thank you for
CodePudding user response:
Seems to not have this kind of method, try the PL
CodePudding user response:
MSSQL? If the MSSQL, direct row_number () over (partition by object the order by the date desc) as NNNN, then select NNNN range and will NNNN reverse order