[sqlite] The problem of inserting data too slow with index

2015-10-30 Thread aa
Hello, I am a sqlite user from asia. I use sqlite for more than a year , now the version i am using is 3.8.11.1. But recently I meet a problem about inserting data into table.It is too slow whit index. The first I create a table like this: CREATE TABLE mac_tb (mac

[sqlite] Why SQLite take lower performance in multi-thread SELECTing?

2015-10-30 Thread sanhua.zh
Hi, all I use SQLite in iOS. I found that SQLite will take lower performancein multi-thread SELECTing. Here is my test result, It costs 0.11s to select 100, elements,in 1-thread SELECTing: But the sameIn 4-thread SELECTing, it costs 0.2s avg. This test run on iPhone 6s. You can see that

[sqlite] How would sqlite read this from disk?

2015-10-30 Thread Simon Slavin
On 30 Oct 2015, at 4:22pm, Mark Hamburg wrote: > I knew it would dirty the whole page. I was thinking about the memory work > and ignoring that the disk I/O swamps that. As someone who is not part of the development team I can write this. I can't answer your question, but your pattern of

[sqlite] Question about Style

2015-10-30 Thread Ramar Collins
Hi Guys, I'm working on a static site generator and want to use SQLite to store metadata. I'm using C and a small library to get the majority of the work done. My question is, do you have any suggestions or know where to find more lore on how to nicely embed SQL in a program like this? Here

[sqlite] Question about Style

2015-10-30 Thread Keith Medcalf
You really should be binding the data values to the prepared statement, not injecting user values into the SQL statement. Unless of course you go to the extrodinary lenghts requires to sanitize your inputs. https://xkcd.com/327/ You should be doing sqlite_prepare_v2 on a statement of the

[sqlite] Feature Request: Support for MMAP beyond 2GB

2015-10-30 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 https://sqlite.org/mmap.html SQLite supports memory mapping databases, but only does so for the first 2GB of the file. My databases are around 4 to 20GB, and completely fit within RAM on my 64 bit systems. The 2GB mmap limit means that only a

[sqlite] SQLITE_NULL values on column of migrated DB

2015-10-30 Thread Andi Palo
Hi folks, I have a problem with version 3.9.1 of sqlite. I have migrated a DB from ms access to sqlite using the tool at http://mdb2sq3.codeplex.com. Some columns are empty either using sqlite3.exe or sqlite3.dll at the current version. Using version 3.8.10.2 (I compiled it by myself), the column

[sqlite] Question about Style

2015-10-30 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 10/30/2015 11:08 AM, Ramar Collins wrote: > I'm working on a static site generator and want to use SQLite to > store metadata. I'm using C and a small library to get the > majority of the work done. My question is, do you have any > suggestions

[sqlite] How would sqlite read this from disk?

2015-10-30 Thread Mark Hamburg
On Oct 30, 2015, at 5:56 AM, Richard Hipp wrote: >> Will SQLite rewrite the whole row if you just change field2 from one float >> to another? > > Yes. Not just the whole row but the whole page on which that row > resides. And even if SQLite did just try to write the 8 bytes that > changes,

[sqlite] How would sqlite read this from disk?

2015-10-30 Thread Richard Hipp
On 10/30/15, Mark Hamburg wrote: > >> On Oct 29, 2015, at 12:24 PM, Richard Hipp wrote: >> >> If you do have large BLOBs or strings, SQLite handles this best if the >> large blob/string is stored in a table by itself and then linked into >> other tables using an integer primary key. For

[sqlite] How would sqlite read this from disk?

2015-10-30 Thread Mark Hamburg
> On Oct 29, 2015, at 12:24 PM, Richard Hipp wrote: > > If you do have large BLOBs or strings, SQLite handles this best if the > large blob/string is stored in a table by itself and then linked into > other tables using an integer primary key. For example: > > CREATE TABLE BigBlobTab ( >

[sqlite] Documentation change suggestion: formatchng.html

2015-10-30 Thread Dominique Pellé
Richard Hipp wrote: > On 10/29/15, Simon Slavin wrote: > > > > On 29 Oct 2015, at 6:58pm, Richard Hipp wrote: > > > >> That page was really old and mostly obsolete - at least the header > >> text was. I've rewritten it. Please press "Reload" > > > > Good. Will it be updated for everything