Re: [sqlite] Calculating the size of a backup

2009-04-03 Thread Brown, Daniel
> boun...@sqlite.org] On Behalf Of Brown, Daniel > Sent: Friday, April 03, 2009 11:42 AM > To: General Discussion of SQLite Database > Subject: [sqlite] Calculating the size of a backup > > Good Morning List, > > Is there any way to calculate the size of a database backup be

[sqlite] Calculating the size of a backup

2009-04-03 Thread Brown, Daniel
Good Morning List, Is there any way to calculate the size of a database backup before doing a backup? I need to know how big the backup database is going to before I call the new backup API: as the backup database is using an in memory VFS. Cheers, Daniel Brown | Software Engineer "The best

Re: [sqlite] Saving and loading SQLite pages from a buffer

2009-02-04 Thread Brown, Daniel
ages from a buffer > > > On Feb 4, 2009, at 6:09 PM, Brown, Daniel wrote: > > > > I currently use SQLite by opening ":memory:" and then copying the > > tables > > I want from read only storage into ":memory:" via an attached read > > o

Re: [sqlite] Saving and loading SQLite pages from a buffer

2009-02-04 Thread Brown, Daniel
-Original Message- >The hot backup API has not yet been released. Look for version 3.6.11. I will look forward to seeing that release! Is there anything I can do to help with the development? >If you open your database using the special name ":memory:" then it is >held entirely in

Re: [sqlite] Saving and loading SQLite pages from a buffer

2009-02-04 Thread Brown, Daniel
04, 2009 2:19 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Saving and loading SQLite pages from a buffer On Feb 4, 2009, at 5:12 PM, Brown, Daniel wrote: > Good Afternoon List, > > I've been looking at how best to save/load SQLite database that is > 100%

[sqlite] Saving and loading SQLite pages from a buffer

2009-02-04 Thread Brown, Daniel
Good Afternoon List, I've been looking at how best to save/load SQLite database that is 100% in memory to and from a memory buffer instead of a file via a VFS operating system wrapper. I had initially thought that implementing a Virtual File System (VFS) was a solution but then I realised that

[sqlite] SQLite version 3.6.10: Memory savings with large pages

2009-01-15 Thread Brown, Daniel
Good morning list, Has anyone else noticed significant memory savings when using larger page sizes since upgrading to 3.6.9 or 3.6.10 (we were on 3.6.1 previously)? We use about 7.32 MB (Peak 9.64 MB) when loading our database into RAM using default settings and using larger page sizes (PRAGMA

Re: [sqlite] SQLite version 3.6.10

2009-01-15 Thread Brown, Daniel
The frequent releases are not a problem as far as I am concerned. I'd rather have bugs fixed quickly when they are discovered, than wait months for releases containing needed fixes like other libraries. We use the loose pre-generated C files (not the amalgamation) and even then it only takes me

[sqlite] Converted sqlite3VdbeSerialTypeLen into a macro

2009-01-14 Thread Brown, Daniel
Good morning list, I've been doing some profiling of SQLite 3.6.1 on PC and some of our other proprietary platforms. It has become evident that the function 'sqlite3VdbeSerialTypeLen' is being hit a lot: enough that the function is adding up to a fair % of program execution time. As the

Re: [sqlite] SQLite performance woe

2008-12-04 Thread Brown, Daniel
Hello Donald, I have managed to speed up some of my SQLite queries by about 300% by writing them from joins to sub queries. I am comparing SQLite against a custom SQL implementation we have here. It looks like it is our cursor implementation that is so much faster than SQLite the regular queries

Re: [sqlite] SQLite performance woe

2008-12-02 Thread Brown, Daniel
ses a rowid as a key, and that is how the row is accessed. A "primary key" is a column which is indexed and which has a unique value, duplicates are not encouraged. You may have many indices on a table, and an index my have as its key values from more than one column. Brown, Daniel wrote:

Re: [sqlite] SQLite performance woe

2008-12-02 Thread Brown, Daniel
to a handful of index node accesses, from minutes to milliseconds. Note that Sqlite is "lite" and only uses one index at a time so thoughtful schema design and query layout is necessary for optimal results. Brown, Daniel wrote: > Hello Donald & Others, > > I have primary keys se

Re: [sqlite] SQLite performance woe

2008-12-02 Thread Brown, Daniel
Hello Donald & Others, I have primary keys set for each of the table but no indicies (that I am aware of) as I simply converted the data from our existing database system which does not support indicies. As my current system only implements primary keys I have no real experience dealing with

[sqlite] SQLite performance woe

2008-12-01 Thread Brown, Daniel
Good evening list, I have been profiling the performance of SQLite version 3.6.1 against my current custom (hacktastic) runtime database solution (which I am hoping to replace with SQLite) and I just got a nasty and unexpected result: SQLite is a lot slower! I am running SQLite completely in

Re: [sqlite] Journal files

2008-12-01 Thread Brown, Daniel
On Dec 1, 2008, at 9:11 PM, Brown, Daniel wrote: > I'm using "PRAGMA journal_mode = MEMORY" combined with an in memory > database ":memory:" on version 3.6.1. And I too am seeing lots of > temporary file activity, which is really killing our performance as >

Re: [sqlite] Journal files

2008-12-01 Thread Brown, Daniel
I'm using "PRAGMA journal_mode = MEMORY" combined with an in memory database ":memory:" on version 3.6.1. And I too am seeing lots of temporary file activity, which is really killing our performance as our storage medium is so slow. -Original Message- From: [EMAIL PROTECTED]

Re: [sqlite] Journal files

2008-12-01 Thread Brown, Daniel
Does that control the creation of all temporary files created at runtime? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of D. Richard Hipp Sent: Monday, December 01, 2008 7:56 AM To: General Discussion of SQLite Database Subject: Re: [sqlite] Journal

Re: [sqlite] Loading database from memory buffer

2008-11-27 Thread Brown, Daniel
of SQLite Database Subject: Re: [sqlite] Loading database from memory buffer -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Brown, Daniel wrote: > However writing a new VFS would > seem to be quite an time consuming solution, If you don't have to worry about implementing the locking functionali

[sqlite] Loading database from memory buffer

2008-11-26 Thread Brown, Daniel
Good afternoon list, Is there any way to open a SQLite databases out of an in memory buffer rather than an operating system file (via a VFS)? The runtime environment of one of our platforms does not have local storage that can be accessed via a normal operating system VFS but via an interface

[sqlite] Generating CRC values for tables

2008-11-26 Thread Brown, Daniel
Good Morning list, Is there any functionality built into SQLite to generate CRC values for tables? We would like to be able to verify that the contents of the table we just updated matches the intended contents. Currently using our old database solution we generate a CRC value for each table

[sqlite] Which TCL distrabution for Windows XP for running SQLite tests?

2008-11-15 Thread Brown, Daniel
Good afternoon list, If I would like to use the TCL based tests on my version of SQLite on Windows XP what would be the recommend TCL distribution to use? Would ActiveTCL (http://tinyurl.com/5wl6uv) be compatible with the SQLite TCL scripts on Windows XP? Cheers, Daniel Brown | Software

Re: [sqlite] Distinguishing between sqlite3_stmts

2008-11-06 Thread Brown, Daniel
] [mailto:[EMAIL PROTECTED] On Behalf Of D. Richard Hipp Sent: Thursday, November 06, 2008 4:54 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Distinguishing between sqlite3_stmts On Nov 6, 2008, at 7:47 PM, Brown, Daniel wrote: > Good afternoon list, > > Are there an

[sqlite] Distinguishing between sqlite3_stmts

2008-11-06 Thread Brown, Daniel
Good afternoon list, Are there any methods for distinguishing between sqlite3_stmt structures prepared by sqlite3_prepare_v2? I'd like to be able to tell if a statement structure has been finalized and then prepared with a different query programmatically. Is there any sort of unique identifier

Re: [sqlite] VFS implementation guidance

2008-11-04 Thread Brown, Daniel
guidance -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Brown, Daniel wrote: > Are there any guides to implementing a VFS (sqlite3_vfs) for SQLite? A > good practices guide would be as useful. I already have an existing > file system API/library for the target system so I guess it is most

[sqlite] VFS implementation guidance

2008-11-04 Thread Brown, Daniel
Good morning list, Are there any guides to implementing a VFS (sqlite3_vfs) for SQLite? A good practices guide would be as useful. I already have an existing file system API/library for the target system so I guess it is mostly just matching up the API with the VFS implementation via some

Re: [sqlite] Vista frustrations

2008-09-17 Thread Brown, Daniel
Has anyone tried to replicate this bug on WindowsXP too? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Roger Binns Sent: Wednesday, September 17, 2008 4:24 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Vista frustrations -BEGIN

[sqlite] Dates & SQLite

2008-09-15 Thread Brown, Daniel
Good morning list, Could someone point me to the documentation regarding dates and SQLite? I'm having trouble finding anything about what data type I should use to store dates in my SQLite tables, should it be a numerical type (integer or real) or a string? Cheers, Daniel Brown | Software

Re: [sqlite] GCC -ffast-math safe version of sqlite3IsNaN

2008-08-27 Thread Brown, Daniel
Database Subject: Re: [sqlite] GCC -ffast-math safe version of sqlite3IsNaN -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Brown, Daniel wrote: > In the process of upgrading to 3.6.1 I've run into the error on line 46 > of util.c about int sqlite3IsNaN(double x) not behaving consistently > wit

Re: [sqlite] GCC -ffast-math safe version of sqlite3IsNaN

2008-08-26 Thread Brown, Daniel
(compiled with -ffast-math)? Mike > -Urspr√ľngliche Nachricht- > Von: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Im Auftrag von Brown, Daniel > Gesendet: Mittwoch, 27. August 2008 00:38 > An: General Discussion of SQLite Database > Betreff: [sqlite] GCC -ffast-math safe versi

[sqlite] GCC -ffast-math safe version of sqlite3IsNaN

2008-08-26 Thread Brown, Daniel
Good afternoon list, In the process of upgrading to 3.6.1 I've run into the error on line 46 of util.c about int sqlite3IsNaN(double x) not behaving consistently with the GCC -ffast-math compiler option (which we have enabled), is there any alternative function I could use that would be

Re: [sqlite] sqlite3_stmt declaration

2008-08-25 Thread Brown, Daniel
Thanks for all the advice, I'll use void* pointers for SQLite internal structures which was my plan B if I couldn't find a declaration to feed the compiler to calm it. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brown, Daniel Sent: Monday, August 25

[sqlite] sqlite3_stmt declaration

2008-08-25 Thread Brown, Daniel
Good afternoon list, I'm attempting to wrap SQLite with Managed C++ and I'm getting some compiler warnings as the compiler/linker is have trouble finding the declaration of the structure 'sqlite3_stmt', I've tried looking for it manually but I can't find it either all I can find is a typedef on

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-25 Thread Brown, Daniel
Interesting, I just tried that in my test application and Dennis's and I get access violations during the vacuum command execution when trying to resize the pages from 1k to 4k with my database or Dennis's test database. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-22 Thread Brown, Daniel
some vbscript to generate a table declaration and insert statements for a csv. I might be able to dig it up if you dont mind vbscript. On Fri, Aug 22, 2008 at 1:58 PM, Brown, Daniel <[EMAIL PROTECTED]> wrote: > I just ran Dennis's test databases through the test application and > w

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-22 Thread Brown, Daniel
- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dennis Cote Sent: Friday, August 22, 2008 7:10 AM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) Brown, Daniel wrote: > 2. And the other thing to try would be if anyone has a fai

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-21 Thread Brown, Daniel
SQLite Memory footprint(!) On Aug 21, 2008, at 7:33 PM, Brown, Daniel wrote: > if anyone has a fairly meaty test > database they don't mind sharing that I could fling at my test > application... A project repository with "fossil" is a (meaty) SQLite database. You could (for ex

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-21 Thread Brown, Daniel
1. Is anyone else on the list using Visual Studio 2005? It would be handy to see if they got similar results with the test application or not, that would rule out the build environment to an extent. 2. And the other thing to try would be if anyone has a fairly meaty test database they don't

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-21 Thread Brown, Daniel
Ok so after reading your feedback I tried: 1. "PRAGMA cache_size =10" no change in memory usage. 2. "PRAGMA page_size = 4096" no change in memory usage. I'm doing both those queries (in C++) after the 'sqlite3_open( ":memory:", _pDataBase );' in my test but before the database file is attached or

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) Brown, Daniel wrote: > I just upgraded to the latest version (3.6.1) of the pre-processed C > source code from the website, running the test again gives me similar > results of 22.2 MB used and 24.55 MB high water from

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
, August 20, 2008 2:43 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) On Aug 20, 2008, at 5:30 PM, Brown, Daniel wrote: > I just upgraded to the latest version (3.6.1) of the pre-processed C > source code from the website, running the test

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
try rebuilding it next. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brown, Daniel Sent: Wednesday, August 20, 2008 1:50 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) That is interesting, all

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of D. Richard Hipp Sent: Wednesday, August 20, 2008 12:14 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) On Aug 20, 2008, at 2:56 PM, Brown, Daniel wrote

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
. Richard Hipp Sent: Wednesday, August 20, 2008 11:44 AM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) On Aug 20, 2008, at 2:22 PM, Brown, Daniel wrote: > sqlite3_memory_highwater() ~ 25673060 > sqlite3_memory_used() ~ 23222709 >

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
(memHigh/1024)); sqlite3_close( pDataBase ); -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of D. Richard Hipp Sent: Wednesday, August 20, 2008 11:00 AM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footp

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
Sent: Wednesday, August 20, 2008 10:44 AM To: General Discussion of SQLite Database Subject: Re: [sqlite] Reducing SQLite Memory footprint(!) On Aug 19, 2008, at 6:24 PM, Brown, Daniel wrote: > SQLite is very memory > intensive compared to our current solution (although SQLite is

Re: [sqlite] Reducing SQLite Memory footprint(!)

2008-08-20 Thread Brown, Daniel
footprint(!) On Aug 19, 2008, at 6:24 PM, Brown, Daniel wrote: > Good afternoon list, > > Are there any known techniques for reducing SQLite's memory footprint? Construct your database into a file (say "test.db"). Then run the sqlite3_analyzer utility (available for dow

[sqlite] Reducing SQLite Memory footprint(!)

2008-08-19 Thread Brown, Daniel
Good afternoon list, Are there any known techniques for reducing SQLite's memory footprint? I am currently evaluating SQLite as a possible replacement to our current proprietary database solution. However SQLite is very memory intensive compared to our current solution (although SQLite is faster

Re: [sqlite] Memory profiling SQLite database

2008-08-18 Thread Brown, Daniel
: [sqlite] Memory profiling SQLite database On Aug 15, 2008, at 5:58 PM, Brown, Daniel wrote: > Good afternoon List, > > Is there any way at runtime to find out how much memory each of my > tables in my database are using, other than loading each table > individually into a :m

[sqlite] Memory profiling SQLite database

2008-08-15 Thread Brown, Daniel
Good afternoon List, Is there any way at runtime to find out how much memory each of my tables in my database are using, other than loading each table individually into a :memory: database and comparing the before and after values? Any sort of ability to generate a memory usage breakdown would

Re: [sqlite] Loading a existing database 100% into memory

2008-08-14 Thread Brown, Daniel
database 100% into memory On Thu, 14 Aug 2008, D. Richard Hipp wrote: > On Aug 14, 2008, at 4:18 PM, Brown, Daniel wrote: > >> Hello Stefan, >> >> I'm trying to use the code snippet you suggested but when I try to >> query >> the master table of t

Re: [sqlite] Loading a existing database 100% into memory

2008-08-14 Thread Brown, Daniel
Hello Stefan, I'm trying to use the code snippet you suggested but when I try to query the master table of the attached database I get and error with the following message: "SQL error: no such table: 'test.sqlite_master'; I am running the following queries: 1. "ATTACH DATABASE

Re: [sqlite] Loading a existing database 100% into memory

2008-08-07 Thread Brown, Daniel
Oberholtzer Sent: Wednesday, August 06, 2008 5:17 PM To: General Discussion of SQLite Database Subject: Re: [sqlite] Loading a existing database 100% into memory On Wed, Aug 6, 2008 at 6:26 PM, Brown, Daniel <[EMAIL PROTECTED]> wrote: > Good afternoon list, > > I would like to load my c

[sqlite] Loading a existing database 100% into memory

2008-08-06 Thread Brown, Daniel
Good afternoon list, I would like to load my current database file completely into memory, mostly as an experiment to check SQLite's maximum memory footprint, however searching through the documentation I can only find references about how to create new databases that are completely memory

[sqlite] Loading from Read Only storage and saving changes to a separate storage unit

2008-07-24 Thread Brown, Daniel
Morning List, Another morning another question, what sort of facilities does SQLite provide for Loading from a read only storage location and then saving changes to a separate read/write storage unit? I know I can open a database file with a read only flag but how would I go about managing the

Re: [sqlite] Cursors in SQlite

2008-07-23 Thread Brown, Daniel
To: sqlite-users@sqlite.org Subject: Re: [sqlite] Cursors in SQlite Brown, Daniel <[EMAIL PROTECTED]> wrote: > Does SQLite support/implement cursors of any form sqlite3_step is, in some sense, a forward-only cursor. You might also find this interesting: http://www.sqlite.org/cvstr

[sqlite] Cursors in SQlite

2008-07-22 Thread Brown, Daniel
Good Evening list, Does SQLite support/implement cursors of any form, I've been searching through the documentation about this but I suspect either cursor is the wrong term for SQLite or they are either not supported or implemented. Could anyone clear this up for me? Cheers, Daniel Brown "The

[sqlite] Taking precompiled test source files from the online repository

2008-07-18 Thread Brown, Daniel
Morning List, As I mentioned yesterday our local build system doesn't support TCL, so I've been taking the appropriate versions of files (we're on 3.5.1 currently) from the online repository for things like the SQLite3 console. I'd quite like to get as many of the original c tests as possible

Re: [sqlite] SQLite3.exe preprocessed source?

2008-07-17 Thread Brown, Daniel
Never mind, I managed to figure out the file I need from the make file in the source repository. For reference the file seems to be shell.c -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brown, Daniel Sent: Thursday, July 17, 2008 3:26 PM To: sqlite

[sqlite] SQLite3.exe preprocessed source?

2008-07-17 Thread Brown, Daniel
Hello List, Is there anywhere I can get the pre-processed C source for the SQLite3.exe console application? I don't have tcl/make set-up here meaning I can't generate the source myself so I've just been working with the pre-processed source files available on the website but these don't seem to

RE: [sqlite] Testing SQLite

2007-12-13 Thread Brown, Daniel
-processed source? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 13 December 2007 10:14 To: sqlite-users@sqlite.org Subject: Re: [sqlite] Testing SQLite "Brown, Daniel" <[EMAIL PROTECTED]> wrote: > Morning List, > > I've just started

[sqlite] Testing SQLite

2007-12-13 Thread Brown, Daniel
Morning List, I've just started experimenting with SQLite to see if I can replace our current custom embedded database solution with it and trying to port SQLite to some of our embedded platforms. Are there are any testing frameworks (unit tests would be great) for SQLite? I'd like to be able to