Re: [sqlite] Statistics on integer primary key

2010-07-30 Thread Peter.Hizalev
Selectivity is known -- since it's a primary key, which is unique -- it will be 1. Cardinality can vary. Peter. -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Kees Nuyt Sent: Friday, July 30, 2010 11:58 AM To:

Re: [sqlite] Optimizing Songbird

2010-07-30 Thread Richard Hipp
On Fri, Jul 30, 2010 at 5:24 PM, Alexey Pechnikov wrote: > 2010/7/31 Richard Hipp : > > (3) Read about the sqlite3_stmt_status() interface. Just before you > > sqlite3_finalize() or sqlite3_reset() each prepared statement, using > > sqlite3_stmt_status()

Re: [sqlite] Optimizing Songbird

2010-07-30 Thread Mike Hays
Hi Richard, Thanks for getting back to me so quickly! :) You're absolutely right that changing memory/cache usage doesn't seem to affect performance much. I've pastebin'd a performance log here: http://mozilla.pastebin.org/434277. It definitely looks like we have some duplicate queries,

Re: [sqlite] Optimizing Songbird

2010-07-30 Thread Alexey Pechnikov
2010/7/31 Richard Hipp : > (3) Read about the sqlite3_stmt_status() interface.  Just before you > sqlite3_finalize() or sqlite3_reset() each prepared statement, using > sqlite3_stmt_status() to see how many full-scan steps and how many sorts it > had to do.  If the answer to

Re: [sqlite] Statistics on integer primary key

2010-07-30 Thread Richard Hipp
On Fri, Jul 30, 2010 at 4:39 PM, Cory Nelson wrote: > On Thu, Jul 29, 2010 at 5:25 PM, wrote: > > Hello, > > > > Consider two tables: > > > >> create table a(num integer primary key); > >> create table b(num integer primary key); > > > > After loading

Re: [sqlite] Statistics on integer primary key

2010-07-30 Thread Cory Nelson
On Thu, Jul 29, 2010 at 5:25 PM, wrote: > Hello, > > Consider two tables: > >> create table a(num integer primary key); >> create table b(num integer primary key); > > After loading both tables we have 100 rows in table a and 1000 in table > b. We make sure b.num is

Re: [sqlite] Optimizing Songbird

2010-07-30 Thread Richard Hipp
On Fri, Jul 30, 2010 at 3:26 PM, Mike Hays wrote: > Hi sqlite-users, > > I'm working on improving the SQLite database performance for Songbird, an > open-source media player based on Firefox/Mozilla. We're seeing pretty poor > performance with large media libraries -

[sqlite] Optimizing Songbird

2010-07-30 Thread Mike Hays
Hi sqlite-users, I'm working on improving the SQLite database performance for Songbird, an open-source media player based on Firefox/Mozilla. We're seeing pretty poor performance with large media libraries - ideally we'd like to support 100,000 media items and maintain reasonable performance.

Re: [sqlite] Statistics on integer primary key

2010-07-30 Thread Kees Nuyt
On Thu, 29 Jul 2010 17:25:50 PDT, wrote: >Hello, > >Consider two tables: > >> create table a(num integer primary key); >> create table b(num integer primary key); > >After loading both tables we have 100 rows in table a and 1000 in table b. >We make sure b.num is a

Re: [sqlite] PRAGMA database_list: insert into table?

2010-07-30 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/30/2010 08:00 AM, Tim Romano wrote: > Several things might be responsible for there being no "outpouring of > support" for a raw reverse function. Also note that you are proposing it as a very specific workaround for a specific scenario which

Re: [sqlite] [PATCH] Verify number of arguments in icuRegexpFunc

2010-07-30 Thread Scott Hess
Ah, OK (I was finding an older different version on the sqlite.org site). Pawel, we could probably modify our patch to use SQLite's change, then on next merge it will go away. Thanks, scott On Thu, Jul 29, 2010 at 10:53 PM, Dan Kennedy wrote: > > On Jul 30, 2010, at

Re: [sqlite] PRAGMA database_list: insert into table?

2010-07-30 Thread Tim Romano
Roger, I'm not thinking of you as a gatekeeper but as a member of the "vocal opposition". You did oppose my request, after all, you didn't simply ignore it. But your opposition was not unreasonable -- it was simply based on certain assumptions that I saw an opportunity to address. Several

Re: [sqlite] Using variable is queries

2010-07-30 Thread Andy Gibbs
On Friday, July 30, 2010 2:40 PM, Igor Tandetnik wrote: > chris23879 wrote: >> I'm tring to create a paging function in sqlite. Is it possible to >> declare >> and use a variable in sqlite. > > No. But since SQLite is embedded in your

Re: [sqlite] typo in src/os_os2.c

2010-07-30 Thread Michael Knigge
> Do you have an OS/2 compile capability? The SQLite developers do not. We > would appreciate your assistance in testing SQLite on OS/2. If you can You don't have OS/2 or you can't get it working? OS/2 is about $US 5 on eBay. AFAIK it runs not under VMWare but I've read that it runs under

Re: [sqlite] Using variable is queries

2010-07-30 Thread Gerry Snyder
On 7/30/2010 5:40 AM, Igor Tandetnik wrote: > chris23879 wrote: >> I'm tring to create a paging function in sqlite. Is it possible to declare >> and use a variable in sqlite. > No. But since SQLite is embedded in your application, you can use variables > in your

Re: [sqlite] Using variable is queries

2010-07-30 Thread Igor Tandetnik
chris23879 wrote: > I'm tring to create a paging function in sqlite. Is it possible to declare > and use a variable in sqlite. No. But since SQLite is embedded in your application, you can use variables in your host programming language. -- Igor Tandetnik

[sqlite] Using variable is queries

2010-07-30 Thread chris23879
Hi I'm tring to create a paging function in sqlite. Is it possible to declare and use a variable in sqlite. For example. DECLARE num INTEGER; SELECT *, num = num + 1 FROM data -- View this message in context: http://old.nabble.com/Using-variable-is-queries-tp29305632p29305632.html Sent

Re: [sqlite] count distinct group by

2010-07-30 Thread Benoit Mortgat
On Thu, Jul 29, 2010 at 00:47, Igor Tandetnik wrote: > Peng Yu wrote: >> I want to select only the rows where if S column are the same, R1 >> column is the same and R2 column is the same. > > select * from mytable where s in > (select s from mytable >  

[sqlite] Sync

2010-07-30 Thread Andy Gable
No virus found in this outgoing message. Checked by AVG - www.avg.com Version: 9.0.851 / Virus Database: 271.1.1/3038 - Release Date: 07/30/10 07:34:00 ___ sqlite-users mailing list sqlite-users@sqlite.org

[sqlite] Comment Correction in vdbemem.c

2010-07-30 Thread Noah Hart
line 1019 /* op can only be TK_REGISTER is we have compiled with SQLITE_ENABLE_STAT2. s/b /* op can only be TK_REGISTER if we have compiled with SQLITE_ENABLE_STAT2. Noah Hart ___ sqlite-users mailing list sqlite-users@sqlite.org

[sqlite] Commenting correction

2010-07-30 Thread Noah Hart
updates.c line 11 **May you do good and not evil. **May you find forgiveness for yourself and forgive others. **May you share freely, never taking more than you give. ** sqlite* ** This file contains C code