[sqlite] combine SELECTs

2015-08-31 Thread Lev
On Sun, 30 Aug 2015 21:26:43 +0200 "R.Smith" wrote: > 1 - Sub-Queries: > > SELECT A.Data, B.Data, C.Data >FROM (SELECT KeyField, Col1 AS Data FROM someTable WHERE Col1 > > 5) AS A JOIN (SELECT KeyField, Col2 AS Data FROM someTable WHERE > Col2 < 10) AS B JOIN (SELECT KeyField, Col3 AS Data

[sqlite] combine SELECTs

2015-08-30 Thread R.Smith
On 2015-08-30 09:02 PM, Lev wrote: > Okay, it is more like an SQL question... > > So I have say three different SELECT on one table. I'd like to combine the > three to have data in the result, only if one particular field is the same for > each query. Might I suggest 2 approaches: (I'm just maki

[sqlite] combine SELECTs

2015-08-30 Thread Lev
Okay, it is more like an SQL question... So I have say three different SELECT on one table. I'd like to combine the three to have data in the result, only if one particular field is the same for each query. I think this is possible with subquery and virtual tables, but I can't really figure out t