Re: [sqlite] Performance question related to multiple processes using sqlite

2013-09-05 Thread Richard Hipp
On Wed, Sep 4, 2013 at 3:51 PM, Varadan, Yamini (SCR US) (EXT) < yamini.varadan@siemens.com> wrote: > > But would any one know if there is any kind of synchronization that is > done between different processes that connect to different sqlite databases > that might slow down one process when

[sqlite] Performance question related to multiple processes using sqlite

2013-09-05 Thread Varadan, Yamini (SCR US) (EXT)
Hello, We use Qt with sqldriver Sqlite-4 in our application. (Windows XP 32 bit, Visual studio 2005) We are facing a performance issue in the following scenario. There are two processes A and B. A uses sqlite DB1 and keeps populating data. Process B uses sqlite DB2 for writing and occasionally

Re: [sqlite] performance question: SELECT max(rowid) - 1

2007-06-14 Thread Guy Hindell
Trey Mack wrote: > I have a fairly large table (10million rows) with a simple INTEGER > PRIMARY KEY AUTOINCREMENT field. > > Executing 'SELECT max(rowid) FROM MyTable' is very fast, as is > 'SELECT min(rowid) FROM MyTable'. > > However, 'SELECT max(rowid) - min(rowid) FROM MyTable' is slow >

Re: [sqlite] performance question: SELECT max(rowid) - 1

2007-06-14 Thread P Kishor
someone else might give a more technical and scientific explanation, but my take is that "SELECT n FROM table" is just that -- a row returned for every row in the table because there is no WHERE clause constraining the results. "SELECT max() - 1 FROM table" on the other hand GROUPs the result

Re: [sqlite] performance question: SELECT max(rowid) - 1

2007-06-14 Thread Guy Hindell
Ah, OK, I see that doing 'SELECT 1 FROM MyTable' returns a 1 for every row, so I can see where the effort is probably going. However, 'SELECT max(rowid) - 1 FROM MyTable' still only produces one result row (obviously I'm experimenting with a much smaller database now). Still need an

[sqlite] performance question: SELECT max(rowid) - 1

2007-06-14 Thread Guy Hindell
I have a fairly large table (10million rows) with a simple INTEGER PRIMARY KEY AUTOINCREMENT field. Executing 'SELECT max(rowid) FROM MyTable' is very fast, as is 'SELECT min(rowid) FROM MyTable'. However, 'SELECT max(rowid) - min(rowid) FROM MyTable' is slow (apparently accessing every

RE: [sqlite] Performance Question

2007-02-12 Thread Slater, Chad
Message- From: Dennis Cote [mailto:[EMAIL PROTECTED] Sent: Monday, February 12, 2007 4:10 PM To: sqlite-users@sqlite.org Subject: Re: [sqlite] Performance Question Slater, Chad wrote: > Hello, > > I'm having trouble with the performance of one of my queries and my "sql > kung fu

Re: [sqlite] Performance Question

2007-02-12 Thread Dennis Cote
Slater, Chad wrote: Hello, I'm having trouble with the performance of one of my queries and my "sql kung fu" is limited. Any help with this problem would be greatly appreciated Here's a stripped down version of the tables I'm dealing with: CREATE TABLE A ( id INTEGER PRIMARY KEY

[sqlite] Performance Question

2007-02-12 Thread Slater, Chad
Hello, I'm having trouble with the performance of one of my queries and my "sql kung fu" is limited. Any help with this problem would be greatly appreciated Here's a stripped down version of the tables I'm dealing with: CREATE TABLE A ( id INTEGER PRIMARY KEY AUTOINCREMENT, name TEXT )

AW: AW: [sqlite] Performance question

2006-09-28 Thread Michael Wohlwend
-Ursprüngliche Nachricht- Von: Martin Pfeifle [mailto:[EMAIL PROTECTED] Gesendet: Dienstag, 26. September 2006 13:35 An: sqlite-users@sqlite.org Betreff: AW: AW: [sqlite] Performance question >Hi Michael, >could you please (re)post the exact create inex statements +primary k

AW: AW: [sqlite] Performance question

2006-09-26 Thread Martin Pfeifle
t; <sqlite-users@sqlite.org> Gesendet: Dienstag, den 26. September 2006, 09:34:00 Uhr Betreff: AW: [sqlite] Performance question -Ursprüngliche Nachricht- Von: Dennis Cote [mailto:[EMAIL PROTECTED] Gesendet: Freitag, 22. September 2006 17:07 An: sqlite-users@sqlite.org Betreff: Re

AW: [sqlite] Performance question

2006-09-26 Thread Michael Wohlwend
-Ursprüngliche Nachricht- Von: Dennis Cote [mailto:[EMAIL PROTECTED] Gesendet: Freitag, 22. September 2006 17:07 An: sqlite-users@sqlite.org Betreff: Re: [sqlite] Performance question Michael Wohlwend wrote: > But If I do "select data from pictures where (x betwee

Re: [sqlite] Performance question

2006-09-22 Thread Dennis Cote
Michael Wohlwend wrote: But If I do "select data from pictures where (x between high_x and low_x) and (y between high_y and low_y) then this takes ca. 8 seconds (!) on wince. Michael, If you are really writing your between clauses as above with the high limit first, then they are not

Re: [sqlite] Performance question

2006-09-22 Thread Martin Jenkins
Michael Wohlwend wrote: I made a database of little pictures, which includes x und y coordinates and Are x and y indexed? Martin - To unsubscribe, send email to [EMAIL PROTECTED]

AW: [sqlite] Performance question

2006-09-22 Thread Michael Wohlwend
-Ursprüngliche Nachricht- Von: Gerald Dachs [mailto:[EMAIL PROTECTED] Gesendet: Freitag, 22. September 2006 11:28 An: sqlite-users@sqlite.org Betreff: Re: [sqlite] Performance question >My sql knowledge may be a little bit rusty and I have really no idea how sqlite is doing "

Re: [sqlite] Performance question

2006-09-22 Thread Gerald Dachs
> But If I do "select data from pictures where (x between high_x and low_x) > and (y between high_y and low_y) then this takes ca. 8 seconds (!) on > wince. My sql knowledge may be a little bit rusty and I have really no idea how sqlite is doing "between" querys. Anyway, once I have learned never

[sqlite] Performance question

2006-09-22 Thread Michael Wohlwend
Hi, I made a database of little pictures, which includes x und y coordinates and a blob (between 100 and 8000 bytes in size, one blob, total db size 180MB). If I do "select data from pictures where x=? And y=?" this works well, also on wince (measured myself: 1 such a select take 5

Re: [sqlite] Performance Question: Ordering of columns

2006-09-08 Thread Dennis Cote
Slater, Chad wrote: Does the ordering of columns in a table have any impact on performance? Chad, Not significantly if your rows have less than a couple of hundred bytes of data. If they are larger than that they will spill into overflow page(s). It takes longer to insert and select data

[sqlite] Performance Question: Ordering of columns

2006-09-08 Thread Slater, Chad
Hello, Does the ordering of columns in a table have any impact on performance? Chad - To unsubscribe, send email to [EMAIL PROTECTED] -

Re: [sqlite] Performance Question

2006-08-30 Thread Rob Sciuk
On Wed, 30 Aug 2006 [EMAIL PROTECTED] wrote: > > I have to go along with Mario, here. This is a potential show stopper, > > Show stopper? Really? The bug has been there for years, literally, > and nobody has even noticed it until now - despite thousands of users > and millions and millions of

Re: [sqlite] Performance Question

2006-08-30 Thread drh
Rob Sciuk <[EMAIL PROTECTED]> wrote: > On Wed, 30 Aug 2006, Mario Frasca wrote: > > On 2006-0829 13:15:02, [EMAIL PROTECTED] wrote: > > > > >> To my surprise (perhaps "horror") I find that SQLite has > > >> for a very long time allowed NULL values in PRIMARY KEY > > >> columns. [...] > > > > I

Re: [sqlite] Performance Question

2006-08-30 Thread Rob Sciuk
On Wed, 30 Aug 2006, Mario Frasca wrote: > On 2006-0829 13:15:02, [EMAIL PROTECTED] wrote: > > >> To my surprise (perhaps "horror") I find that SQLite has > >> for a very long time allowed NULL values in PRIMARY KEY > >> columns. [...] > > I understand your concern about legacy programs, but most

Re: [sqlite] Performance Question

2006-08-30 Thread Mario Frasca
On 2006-0829 13:15:02, [EMAIL PROTECTED] wrote: To my surprise (perhaps "horror") I find that SQLite has for a very long time allowed NULL values in PRIMARY KEY columns. [...] I understand your concern about legacy programs, but most of us expect PRIMARY KEY to imply NOT NULL... don't

Re: [sqlite] Performance Question

2006-08-29 Thread drh
Kurt Welgehausen <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > > Saying NOT NULL on a PRIMARY KEY is redundant, by the way. > > -- > > D. Richard Hipp <[EMAIL PROTECTED]> > > sqlite> insert into t (k, d) values (null, 'jkl'); > sqlite> select * from t; > k d >

Re: [sqlite] Performance Question

2006-08-29 Thread Mario Frasca
Mario Frasca wrote: Kurt Welgehausen wrote: [...] should I write a bug ticket about a primary key accepting nulls? there is already a ticket for that: 518. I reopened it three days ago. I have right now attached a patch for it. it is quite small and I hope it fits in the current

Re: [sqlite] Performance Question

2006-08-29 Thread Mario Frasca
Kurt Welgehausen wrote: [EMAIL PROTECTED] wrote: Saying NOT NULL on a PRIMARY KEY is redundant, by the way. [...] Am I missing something, or should I write a bug ticket about a primary key accepting nulls? there is already a ticket for that: 518. I reopened it three days ago.

Re: [sqlite] Performance Question

2006-08-28 Thread Derrell . Lipman
Kurt Welgehausen <[EMAIL PROTECTED]> writes: > [EMAIL PROTECTED] wrote: > >> Saying NOT NULL on a PRIMARY KEY is redundant, by the way. >> -- >> D. Richard Hipp <[EMAIL PROTECTED]> > > **kaw<~/tdpsa>$ sqlite3 > Loading resources from /home/kaw/.sqliterc > SQLite version 3.3.7 > Enter ".help"

Re: [sqlite] Performance Question

2006-08-28 Thread Kurt Welgehausen
[EMAIL PROTECTED] wrote: > Saying NOT NULL on a PRIMARY KEY is redundant, by the way. > -- > D. Richard Hipp <[EMAIL PROTECTED]> **kaw<~/tdpsa>$ sqlite3 Loading resources from /home/kaw/.sqliterc SQLite version 3.3.7 Enter ".help" for instructions sqlite> .nullvalue '<>' sqlite> create table

Re: [sqlite] Performance Question

2006-08-28 Thread drh
"Slater, Chad" <[EMAIL PROTECTED]> wrote: > Hello, > > Consider the following lookup table definition: > > CREATE TABLE foobar ( > id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, > table1_id INTEGER NOT NULL REFERENCES table1, > table2_id INTEGER NOT NULL REFERENCES table2 > ); > >

[sqlite] Performance Question

2006-08-28 Thread Slater, Chad
Hello, Consider the following lookup table definition: CREATE TABLE foobar ( id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, table1_id INTEGER NOT NULL REFERENCES table1, table2_id INTEGER NOT NULL REFERENCES table2 ); The id primary key column is not necessary for anything in my

RE: [sqlite] performance question

2004-03-17 Thread Williams, Ken
> On my PC the following query requires about 53 seconds: > select * from TABG a, TABB b where (a.S='3' or a.S='12 or...) and > b.G=a.G order by a.G asc; > > (On Oracle with the same scheme and data it requires only 0.4 > seconds.) In my experience, even though SQLite has very low overhead

Re: [sqlite] performance question

2004-03-17 Thread godot
Hi, > I have a question about the performance of my SQLite DB, where the > db-file has about 20MB and which I use in a Java application via the > Java wrapper. First, your timing figures look indeed slower than what I would expect (using a somewhat similar DB in type and size and a similar