Skip to content
Prev 316727 / 398506 Next

Filter according to the latest data

On Fri, Feb 1, 2013 at 8:05 AM, nalluri pratap <pratap_stat at yahoo.co.in> wrote:
HAVING is only used to select groups and only works by chance in this
example but if the data were to change then it would likely not work.

Try this instead.  It makes use of an sqlite-specific feature that
guarantees that when MAX is used in a GROUP BY that the other columns
will be from the same row:
ID  No    Change       Date
1  D 111     final 2013-01-12
2  C 123 bug fixed 2013-01-17


--
Statistics & Software Consulting
GKX Group, GKX Associates Inc.
tel: 1-877-GKX-GROUP
email: ggrothendieck at gmail.com