Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I'm doing a count statement where I only want to include the matching record in the count if it is the first record by date
i.e. In the records below if I was counting the amount of ID's that had a letter of B. I would only include the one from the 2nd ID (456) as B is the first chronologically.
ID | DATE | LETTER |
---|---|---|
123 | 01/08/2018 | A |
123 | 02/08/2018 | B |
123 | 03/08/2018 | C |
ID | DATE | LETTER |
---|---|---|
456 | 01/08/2018 | B |
456 | 02/08/2018 | A |
456 | 03/08/2018 | C |
Any help would be much appreciated.
the function firstsortedvalue()