On Wed, Nov 18, 2015 at 11:22:51PM -0700, Keith Medcalf wrote:
> On Wednesday, 18 November, 2015 20:36, Nico Williams <nico at 
> cryptonector.com> said:
> > On Thu, Nov 19, 2015 at 12:39:41AM +0000, Simon Slavin wrote:
> > > On 19 Nov 2015, at 12:26am, Nico Williams <nico at cryptonector.com> 
> > > wrote:
> > > > two concurrent scans of the same table should be able to go faster
> > > > than the same two scans in series.
> >
> > > SQLite is not processor-bound, it's file-bound.  Both
> > > threads/processes need to continually read blocks from disk and a disk
> > > can only answer one request at a time.
>  
> > Two table scans of the same data in sequence are going to cost more than
> > two table scans of the same data concurrently.
> 
> The original was taking about the "same table".  "same data" is
> somewhat sloppy terminology.  Assuming that "same data" == "same

It was sloppy.  In fact, it was wrong: it's not the same data because
it's a UNION ALL of two queries each of which will be scanning a
different table, not the "same data".

Nico
-- 

Reply via email to