SQL Select Max Date with Multiple records

后端 未结 1 501
后悔当初
后悔当初 2021-02-14 23:16

I am struggling with a query to pull most recent entries. I have a Notes table that contains the following columns:

BusinessDate
ReportGuid
NoteGuid
Note
NoteDa         


        
1条回答
  •  北荒
    北荒 (楼主)
    2021-02-14 23:40

    You need to group by ReportGuid and select Max(NoteDate). That will select the maximum of each group.

    0 讨论(0)
提交回复
热议问题