Dan Kennedy <danielk1...@...> writes:

[...]

> >
> > Most INSERTS are done into the table Verteilerdaten (>10,000,000).
> > I think the time depends heavily on the activated FOREIGN KEYs - is
> > my assumption correct and is this a behaviour I only can avoid by not
> > switching this PRAGMA on?
 

[...]

> 
> If you insert a row into a table that has a foreign key constraint,
> it has to search for the corresponding key in the parent table. So
> if the parent table is also large (too large for the cache), those
> searches might be slowing you down significantly. So if you can get
> away with doing the inserts with foreign keys turned off, it is
> worth trying.

[...]

Now I'm pretty sure that mass INSERTs and FOREIGN KEYs are not a couple
belonging together (at least in sqlite) - after almost 24 hours I stopped the
whole thing. Next try will be without FKs. I'll post the results - for those
that are interested.

Oliver

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to