Re: How to group this?

Simon Slavin <[email protected]>
Newsgroups gmane.comp.db.sqlite.general
Message-ID <[email protected]>
On 10 Feb 2020, at 1:25am, [email protected] wrote:

> Here is one way that appears to generate the correct result.

Another way: create two VIEWs, one for systolic, one for diasystolic.  Index both VIEWs on (id, date), then JOIN ON id AND date.  If you want to, you could use this to make a third VIEW which would have the systolic and diasystolic figures on the same row.

If you are going to do more than just this on that data convert the dates to YYYYMMDD form or to an integer day number to make searching and sorting easier.  If you're not confident with programming you could do this in SQLite using CASE for the month name.
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.