On 12 Aug 2016, at 10:34pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
> In the past I worked (I think) with a database (not SQLite) where I could > usedAfter in the definition for ratioTotalUsed. It is not a very big > problem, but is something like that possible with SQLite? Sorry, but you cannot do this in SQLite. You cannot rely on usedAfter being already defined when you are defining ratioTotalUsed. You must define ratioTotalUsed in terms of the memUsageLine table. There is a way to do it. You define a first VIEW which calculates usedAfter and includes some other fields from the TABLE, when you define a second VIEW which takes its values from the first VIEW. In your example this is not worth the extra processing since it is easy to calculate (totalAfter-freeAfter), but it can be useful when aggregate functions are used. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users