Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread james ni
[sqlite] What's the level of B+-Tree ? On 8/11/17, Scott Robison wrote: > My understanding is that SQLite doesn't use the traditional definition of > b-tree because it doesn't use fixed size records/keys. It will cram as few > or as many as possible. Correct. More rec

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Richard Hipp
On 8/11/17, Scott Robison wrote: > My understanding is that SQLite doesn't use the traditional definition of > b-tree because it doesn't use fixed size records/keys. It will cram as few > or as many as possible. Correct. More records crammed into one page means that fewer pages need to be read,

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Simon Slavin
On 11 Aug 2017, at 4:16pm, james ni wrote: > Yes, yes, that's what I'm seeking What is it that you’re ultimately trying to do with this information ? Are you doing research on the file format for forensic purposes ? Are you trying to edit the database file without using the SQLite libr

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Scott Robison
9:16 AM, "james ni" wrote: > Yes, yes, that's what I'm seeking > > > From: sqlite-users on > behalf of R Smith > Sent: Friday, August 11, 2017 18:25 > To: sqlite-users@mailinglists.sqlite.org > Subject: Re: [sqlite]

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread james ni
Yes, yes, that's what I'm seeking From: sqlite-users on behalf of R Smith Sent: Friday, August 11, 2017 18:25 To: sqlite-users@mailinglists.sqlite.org Subject: Re: [sqlite] What's the level of B+-Tree ? On 2017/08/11 11:08 AM, Clemen

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Niall O'Reilly
On 11 August 2017 11:08:02 GMT+01:00, james ni wrote: >Maybe we are talking the different thing. > > >Background of my problem: > >1, When one table grows larger, I found the INSERT speed is becoming >slower and slower; It seems to me that you may have chosen to view the problem from an angle whi

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread R Smith
On 2017/08/11 11:08 AM, Clemens Ladisch wrote: james ni wrote: As in the example that I provided, there are 4 cells in a single btree page. So there must be some mechanism to determine hoe many keys that one cell can own. I want to know exactly the very value and just how to change the value t

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Clemens Ladisch
james ni wrote: > the INSERT speed is becoming slower and slower; > > the number of syscalls are increasing quickly; Insert the largest values last. Increase the cache size: . Decrease the amount of data stored in the index. (This is unlikely

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread james ni
017 18:08 To: SQLite mailing list Subject: Re: [sqlite] What's the level of B+-Tree ? Maybe we are talking the different thing. Background of my problem: 1, When one table grows larger, I found the INSERT speed is becoming slower and slower; 2, My task is to make it not so slower; 3, The

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread james ni
know. From: sqlite-users on behalf of Rowan Worth Sent: Friday, August 11, 2017 17:09 To: SQLite mailing list Subject: Re: [sqlite] What's the level of B+-Tree ? Jump to the byte offset specified by the "start of the cell content" header, which comes just after

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Rowan Worth
ly the very value and just how to change the value to > a larger one, for example, 256, 512, or even larger. > > > From: sqlite-users on > behalf of Hick Gunter > Sent: Friday, August 11, 2017 16:31 > To: 'SQLite mailing list' > Su

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Clemens Ladisch
james ni wrote: > As in the example that I provided, there are 4 cells in a single btree > page. So there must be some mechanism to determine hoe many keys that > one cell can own. One key per cell: | Within an interior b-tree page, each key and the pointer to its | immediate left are combined int

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread james ni
, for example, 256, 512, or even larger. From: sqlite-users on behalf of Hick Gunter Sent: Friday, August 11, 2017 16:31 To: 'SQLite mailing list' Subject: Re: [sqlite] What's the level of B+-Tree ? The number of keys in an sqlite index page depend

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread Hick Gunter
Nachricht- Von: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] Im Auftrag von ni james Gesendet: Freitag, 11. August 2017 04:57 An: sqlite-users@mailinglists.sqlite.org Betreff: [sqlite] What's the level of B+-Tree ? In the "SQLite File Format" docu

Re: [sqlite] What's the level of B+-Tree ?

2017-08-11 Thread james ni
found there are plenty of disk IO access during INSERT when one table grows larger. So I suspect the value of "n" should be much smaller. From: sqlite-users on behalf of Clemens Ladisch Sent: Friday, August 11, 2017 14:41 To: sqlite-users@mailinglists

Re: [sqlite] What's the level of B+-Tree ?

2017-08-10 Thread Clemens Ladisch
ni james wrote: > In the "SQLite File Format" document, the BTree layout is described, > but now I want to know how to get the BTree level (which is the 'K' > value mentioned in the Documentation)? At the end of section 1.5, a "K" is defined. But I don't think that is the same K. Anyway, the doc

[sqlite] What's the level of B+-Tree ?

2017-08-10 Thread ni james
In the "SQLite File Format" document, the BTree layout is described, but now I want to know how to get the BTree level (which is the 'K' value mentioned in the Documentation)? Generally, one B+Tree segment contains K keys and (K+1) pointers to child segments. From the source code, I found su