Does SQLite provide any tools to help the
developer tune the database cache size?
Thanks,
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
every day if you have to.
Thanks to you and the team for such a wonderful product.
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
badly that SQLite can't
even execute the pragma.
Writing to the middle of the file -- even a large swath
of garbage -- does undetected by the pragma.
I was hoping that the integrity checking pragma would be
more robust than this. Am I missing something?
Thanks,
- Richard Klein
does undetected = goes undetected
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
that the programs you run aren't
messed with?
We're confident of our file system, because we've never had
any problems with it. However, we have seen some nasty data
corruption problems with our current database system, which
we hope to eliminate by converting to SQLite.
- Richard Klein
about memory? :-)
Thanks!
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
an EXCLUSIVE lock, which
locks out all other transactions until the first one commits.
This works fine in an embedded application where there are only a
few threads, whose transactions execute quickly.
- Richard Klein
___
sqlite-users mailing list
sqlite
On the page describing the various sqlite3_bind_xxx_yyy() functions:
http://www.sqlite.org/c3ref/bind_blob.html
3rd paragraph:
The index for named parameters can be looked up using the
sqlite3_bind_parameter_name() API if desired.
should be:
... sqlite3_bind_parameter_index() ...
company often needs to compile SQLite under C++, so we ran into the
same problem. It's easy to get rid of the error messages: Mostly it's
a matter of adding explicit typecasts, and of separating nested structs.
- Richard Klein
___
sqlite-users mailing list
Stephen Oberholtzer wrote:
On Tue, May 27, 2008 at 3:59 PM, Richard Klein [EMAIL PROTECTED]
wrote:
On May 26, 2008, at 3:24 PM, A. H. Ongun wrote:
Now, when I change the compiler to ppc_82xx-g++ from ppc_82xx-gcc I
get hundreds of error messages.
I am puzzled to see why this is so.
My
Roger Binns wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Richard Klein wrote:
Are there any GUI-based tools that provide
management of a remote SQLite database?
SQLite is an in process database and only provides code that ultimately
calls the operating system's open/read/write
Federico Granata wrote:
I was hoping there might be a client/server management tool out there.
I would need the source code, since the server part would need to be
ported to my embedded device.
Maybe you haven't yet read this http://www.sqlite.org/serverless.html
There isn't a sqlite server
Are there any GUI-based tools that provide
management of a remote SQLite database?
I'm looking for a workstation-based tool
that will allow me to manage a database
on an embedded device.
Thanks in advance,
- Richard Klein
___
sqlite-users mailing list
Does anybody have any thoughts on this proposed behavior changes for
the sqlite3_close() interface?
D. Richard Hipp
[EMAIL PROTECTED]
Fine with me.
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080
this
will hit release?
Regarding the new PRAGMA journal_mode:
Since PERSIST is likely to be faster than DELETE on
most platforms, is there ever a reason *not* to use
it?
Put differently, is there any advantage to DELETE
over PERSIST?
- Richard Klein
I have a question about the new PRAGMA journal_mode:
Since PERSIST is likely to be faster than DELETE on
most platforms, is there ever a reason *not* to use
it?
Put differently, is there any advantage to DELETE
over PERSIST?
- Richard Klein
___
sqlite
to enable Scary Feature X, if that's really a concern add more
arbitrary stuff, or append _notreally or whatever makes you
comfortable.
-scott
On Mon, Apr 21, 2008 at 6:31 PM, Richard Klein
[EMAIL PROTECTED] wrote:
D. Richard Hipp wrote:
On Apr 21, 2008, at 9:03 PM, Richard Klein wrote:
I
I have a question about the new PRAGMA journal_mode:
Since PERSIST is likely to be faster than DELETE on
most platforms, is there ever a reason *not* to use
it?
Put differently, is there any advantage to DELETE
over PERSIST?
- Richard Klein
Richard Klein wrote:
Does SQLite have a mechanism, in addition to the
ANALYZE statement, for recording and dumping
performance statistics?
What kind of performance statistics are you looking for?
SQLiteSpy (see
http://www.yunqa.de/delphi/doku.php/products/sqlitespy/index) measures
Does SQLite have a mechanism, in addition to the
ANALYZE statement, for recording and dumping
performance statistics?
Thanks,
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite
) Logically, specifying OMIT_VIEW should be enough to omit sqlite3-
MaterializeView() -- I shouldn't have to additionally specify OMIT_
TRIGGER.
- Richard Klein
Mark Spiegel wrote:
This was a problem for me too. I just chalked it up to deleting options
and using the amalgamated source. (Seem
You can call sqlite3_memory_highwater() to find
the maximum amount of memory (in bytes) that your
app has used.
Then you can divide this number by 2000 (the default
size of a page) to determine the max number of pages
that have been cached.
- Richard Klein
Ralf Junker wrote:
I need to retrieve
You're right! A grep of the source code confirms
that. My mistake.
- Richard
Jay A. Kreibich wrote:
On Tue, Apr 22, 2008 at 03:33:27PM -0700, Richard Klein scratched on the wall:
You can call sqlite3_memory_highwater() to find
the maximum amount of memory (in bytes) that your
app has used
.
Is this the correct behavior? If so, fine --
it's just that I would have expected sqlite3_
prepare() to return an error code.
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Richard Klein wrote:
In order to reduce SQLite's memory footprint in my embedded
application, I want to use the SQLITE_OMIT_xxx options to
remove unneeded features from SQLite.
Using Cygwin running on Windows, I have successfully down-
loaded the canonical sources and autoconfigured
amalgamated source, you may find a few other small
problems when building your app, but they are easy to fix.
Richard Klein wrote:
Richard Klein wrote:
In order to reduce SQLite's memory footprint in my embedded
application, I want to use the SQLITE_OMIT_xxx options to
remove unneeded
I regenerated and recompiled the source files
specifying that the following features (among
others) are to be omitted:
SQLITE_OMIT_REINDEX
SQLITE_OMIT_VIEW
SQLITE_OMIT_VIRTUALTABLE
Nevertheless, I am getting the following link
errors:
delete.obj : error LNK2019: unresolved external symbol
D. Richard Hipp wrote:
On Apr 21, 2008, at 9:03 PM, Richard Klein wrote:
I regenerated and recompiled the source files
specifying that the following features (among
others) are to be omitted:
SQLITE_OMIT_REINDEX
SQLITE_OMIT_VIEW
SQLITE_OMIT_VIRTUALTABLE
It worked OK when I tried
I fixed my OPTS in the Makefile so that they are in sync
with my compilation options.
Now all the unresolved references in the parser have dis-
appeared, but I'm still left with two unresolved references
to the function sqlite3MaterializeView():
delete.obj : error LNK2019: unresolved external
In order to reduce SQLite's memory footprint in my embedded
application, I want to use the SQLITE_OMIT_xxx options to
remove unneeded features from SQLite.
Using Cygwin running on Windows, I have successfully down-
loaded the canonical sources and autoconfigured the Makefile.
The Makefile seems
On Apr 15, 2008, at 10:34 PM, Richard Klein wrote:
I compiled SQLite 3 (version 3.5.7), specifying
SQLITE_OMIT_TRIGGER to reduce the size of the
generated code.
The OMIT macros are not supported in the preprocessed source
code or in the amalgamation. To use the OMIT macros you much
I compiled SQLite 3 (version 3.5.7), specifying
SQLITE_OMIT_TRIGGER to reduce the size of the
generated code.
I got the following compilation warnings in
parse.c:
-
parse.y(990) : error C2220: warning
Jeff Gibson wrote:
One thing your earlier suggestion brought up. The way I was hooking up
tables before was something along the lines of:
CREATE TABLE primary(id1 INTEGER PRIMARY KEY, primary_fields);
CREATE TABLE secondary(id2 INTEGER PRIMARY KEY, secondary_fields);
CREATE TABLE link(id1
Jay A. Kreibich wrote:
On Thu, Apr 10, 2008 at 05:58:59PM -0700, Richard Klein scratched on the wall:
My advice would be to try it and see. If table creation takes too long,
you can always remove the UNIQUE constraint, and then write a routine to
check the table for uniqueness after it's
The web page http://www.sqlite.org/compile.html contains the
following typo:
SQLITE_OMIT_TRIGGER
Defining this option omits support for VIEW objects...
It should read:
... omits support for TRIGGER objects...
- Richard
___
sqlite-users mailing list
I'm pretty new to databases, and I have a schema design question. I
don't know enough about the guts of how sqlite works to know how to make
some tradeoffs. I have a large (potentially millions of entries) table
and it has 4 columns which are needed for every entry, and 4 more that
containing mostly
NULLs in the secondary columns.
Of course, this approach would cost you some extra space, in the form
of the 5th primary column containing the secondary ROWID.
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http
:
Foreign keys: http://en.wikipedia.org/wiki/Foreign_key
SQLite triggers: http://www.sqlite.org/lang_createtrigger.html
Hope this helps,
- Richard
Thanks! I'll give that a try.
Jeff
Richard Klein wrote:
Whether or not the the secondary columns are needed is a function of one
, but I was worried about
the overhead it would take to enforce them when I'm creating the
database. Do you know if a uniqueness constraint, for instance, does an
O(N) search on each insertion? If so, it sounds prohibitive.
Thanks,
Jeff
Richard Klein wrote:
Jeff,
I think that's
On second thought, checking the entire table for uniqueness would seem
to require O(N log N), regardless of whether it is done one INSERT at
a time, or all at once after the table is created!
- Richard
Richard Klein wrote:
Quoting from the description of CREATE TABLE in the SQL Syntax section
from a few schemas that I've seen. I'm just trying to understand the
trade-offs.
Thanks a lot for your help,
Jeff
Richard Klein wrote:
On second thought, checking the entire table for uniqueness would seem
to require O(N log N), regardless of whether it is done one INSERT
'/';
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
in the (e)mail!
One question: I thought that the '\' character is not part of the
SQL standard. (That's why I specified '/' instead as my ESCAPE
character).
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin
Richard Klein [EMAIL PROTECTED]
wrote:
One question: I thought that the '\' character is not part of the
SQL standard. (That's why I specified '/' instead as my ESCAPE
character).
I'm not sure I understand. You can use any character as an escape
character. E.g. LIKE '2!_%' ESCAPE
On 4/9/08, Richard Klein [EMAIL PROTECTED] wrote:
Richard Klein [EMAIL PROTECTED]
wrote:
One question: I thought that the '\' character is not part of the
SQL standard. (That's why I specified '/' instead as my ESCAPE
character).
I'm not sure I understand. You can use any character
On Mar 31, 2008, at 10:00 PM, Richard Klein wrote:
I just downloaded 3.5.7, and noticed that there is a
new memory allocator mem5.c, which apparently uses the
buddy system to allocate power-of-two-sized chunks
of memory from a static pool. This allocator is used
by defining
)_create_function() have changed, as have the parameters passed to your
user-defined function.
If people are interested, I can turn this into documentation (Wiki article?)
for the SQLite website.
Regards,
- Richard Klein
PM, Richard Klein
[EMAIL PROTECTED] wrote:
I've recently upgraded from SQLite 2.8.17
to 3.5.6.
Upon running a test program that measures
the execution time of SQL statements typical
for my application, I've noticed a definite
performance degradation:
INSERT: 34% slowdown
exper-
imental (and therefore liable to disappear in a future
release)?
Thanks,
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
. the high water mark);
(4) Recompile with SQLITE_MEMORY_SIZE = high_
water_mark + 20% (or whatever).
- Richard
Richard Klein wrote:
I've been porting 3.5.6 to my company's embedded
platform. I've implemented a custom VFS, and a
custom Mutex subsystem, and these seem to work
just fine.
I tried
I've been porting 3.5.6 to my company's embedded
platform. I've implemented a custom VFS, and a
custom Mutex subsystem, and these seem to work
just fine.
I tried to implement a custom Memory subsystem,
but I see that as of 3.5.2 the compilation option
SQLITE_OMIT_MEMORY_ALLOCATION is no longer
I've recently upgraded from SQLite 2.8.17
to 3.5.6.
Upon running a test program that measures
the execution time of SQL statements typical
for my application, I've noticed a definite
performance degradation:
INSERT: 34% slowdown
UPDATE: 47%
DELETE: 50%
Has anyone else
I seem to recall a post from someone (drh?)
stating that the Old School dot-locking
routines one sees in the amalgamation have
not yet been thoroughly tested and should
not be used.
Is this still true?
Thanks,
- Richard
___
sqlite-users mailing list
Ken -
You could write your own VFS that overrides the xOpen method
so that it doesn't create a journal file. Quoting from the
documentation:
The file I/O implementation can use the object type flags to
change the way it deals with files. For example, an application
that does not care about
, be sure to test all use cases.
Denormalization tends to speed up SELECTs at the expense
of slowing down INSERTs, UPDATEs, and DELETEs.
- Richard Klein
[EMAIL PROTECTED] wrote:
Lee Crain [EMAIL PROTECTED] wrote:
I am debating the performance gains to be realized, if any, by indexing a
particular
: no such column: blah.user.id
sqlite
Should the result of a subselect have a table name? If not, how do you
reference it?
select * from (select id from user where id = 1);
- Richard Klein
___
sqlite-users mailing list
sqlite-users@sqlite.org
http
, will recreate the database being dumped.
Can't you just remove the CREATE TABLE statements manually, or
pipe the output of .dump to sed or awk?
Regards,
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
to write to the
database, you must ROLLBACK the first transaction, sleep for a bit, and
restart the first transaction.
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
Consortium is a membership association dedicated to
insuring the continuing vitality and independent of SQLite.
should be:
... independence of SQLite.
^^
Richard Klein
-
To unsubscribe, send email
to
reduce/minimize the lock issue?
There is no way to reduce/minimize the lock issue. Database is locked
is a normal error return that your polling app must be prepared to deal
with. As other folks have noted, the way to deal with it is to sleep for
awhile and then retry the SELECT.
- Richard
Surely I'm not the first person to notice that
SQLite is part of Google's open-source Android
platform for mobile phones.
This is a *huge* win for SQLite ...
- Richard Klein
-
To unsubscribe, send email to [EMAIL
The previous statement is actually more general: SQLite
version 3.x.y can read and write any database created by
any prior version of SQLite.
Even SQLite 2.w.z ?
-
To unsubscribe, send email to [EMAIL PROTECTED]
a reputation for being very
reliable.] Over two-thirds of the source code ...
o *SQLite is well supported.* The SQLite code base is
supported by an international team of developers ...
Something along those lines ...
Cheers,
- Richard Klein
[EMAIL PROTECTED] wrote:
What? And encourage people to write multitheaded programs?
Not likely...
I've been meaning to ask ... When you say that multiple threads
are evil, do you mean as opposed to multiple processes? Or
do you feel that multiprogramming in general is evil?
- Richard Klein
job of rendering most web content (probably because most
web designers optimize for IE).
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
SQLite. On the right, it shows all
the news of interest to an experienced SQLite user. It thus
satisfies a wide audience at a single glance. Perfect!
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
or weeks of frustration
saved working on SQLite instead.
AMEN!
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
, uncluttered, and minimalist.
I don't think the fonts are ugly at all, at least not in IE6.
(What's so ugly about Times? It's the most popular font in
the world.)
(4) is also fine, if you insist on using CSS...
- Richard Klein
John Stanton wrote:
How about having adding a social networking capability so that
non-technical people will have a reason to use the website. You cannot
expect to attract them with a frugal and highly functional embedded
database library.
LOL!
- Richard
.
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
(or process)
can modify the database until thread A commits. (That's what atomic
transaction means!)
In the above scenario, thread B will likely get a SQLITE_BUSY when he
tries to UPDATE. He should sleep for awhile and try again.
- Richard Klein
Richard Klein wrote:
John Firebaugh wrote:
I take it this mean that if, say, thread A begins a transaction, and
modifies the database, then thread B modifies the database, then thread
A commits the transactions, B's modifications are also committed?
Nope. Once thread A begins a transaction
Dan Kennedy wrote:
On 11/1/07, Richard Klein [EMAIL PROTECTED] wrote:
In implementing xLock in a VFS, do we need to worry
about lock counts, i.e. nested locking?
No. You don't need to worry about that.
In other words, if a process asks for, say, a SHARED
lock, and he already has one, should
Joe Wilson wrote:
--- Richard Klein [EMAIL PROTECTED] wrote:
In implementing xLock in a VFS, do we need to worry
about lock counts, i.e. nested locking?
In other words, if a process asks for, say, a SHARED
lock, and he already has one, should we increment a
SHARED lock count? Or is it okay
Dan Kennedy wrote:
From SQLite's point of view, locks are on a per file-handle basis. If
a unix process that uses sqlite has two file-handles open on the same
file (i.e. because the user has opened two separate connections with
two calls to sqlite3_open()), SQLite expects them to be able to
,
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
that an
application invoke:
int sqlite3_initialize(...);
Sounds good to me. I would also recommend adding:
int sqlite3_finalize(...);
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
But am I correct in assuming that one way that SQLite provides
serializable transactions is by automatically rolling back
transactions when necessary (and returning SQLITE_IOERR)?
Thanks,
- Richard Klein
[EMAIL PROTECTED] wrote:
Ken [EMAIL PROTECTED] wrote:
BEGIN TRANSACTION;
SELECT balance
Trevor Talbot wrote:
On 10/29/07, Richard Klein [EMAIL PROTECTED] wrote:
But am I correct in assuming that one way that SQLite provides
serializable transactions is by automatically rolling back
transactions when necessary (and returning SQLITE_IOERR)?
No. That will happen in some specific
. This includes
simple database accesses, even reads.
I think that's a perfectly acceptable solution, if you can live with the
performance hit (and it sounds like you can).
- Richard Klein
-
To unsubscribe, send email
BEGIN EXCLUSIVE.
That's true. If you begin your transaction with BEGIN EXCLUSIVE, then
it cannot be interrupted by another transaction wishing to write to the
database, so rollback won't be an issue.
- Richard Klein
Dan Kennedy wrote:
On Wed, 2007-10-24 at 21:38 -0700, Richard Klein wrote:
As I was thinking about the locking mechanism in SQLite 3,
it occurred to me that the following race condition could
occur.
Imagine a joint bank account with a balance of $10,000.
The wife makes a withdrawal of $1,000
Trevor Talbot wrote:
On 10/25/07, Richard Klein [EMAIL PROTECTED] wrote:
Trevor Talbot wrote:
The thing is, SQLite's synchronization mechanism is simpler than most
full-featured SQL databases. In all cases, the point is that if you
are attempting to do simultaneous writes from two connections
by practical experience: Whenever we find
a difference in behavior between the WIN32 platform and
platform 'X', the difference is almost invariably due to a
bug in the porting layer for one of those two platforms.
Thanks,
- Richard Klein
deal with this error by going back to the start of the
transaction and starting over.
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
Joe Wilson wrote:
--- Richard Klein [EMAIL PROTECTED] wrote:
I should be able to use your test suite
s/your/the/
Sqlite and its test suite are drh's work.
Hmm ... Somehow I got the impression that the team of SQLite
core developers had expanded to include a few folks in addition
to drh
the point of view of the lock state defin-
itions) and pager-level policies (what is actually done in
practice).
Does this seem like a reasonable idea? More importantly,
will it work (not break SQLite)?
Thanks,
Richard Klein
Joe Wilson wrote:
Just implement it and run the test suite.
It's easier to respond to a specific problem than a hypothetical.
Is the test suite available only in Tcl? Or is there a C version
as well?
Thanks,
- Richard Klein
between OS-level policies
(what is legal from the point of view of the lock state defin-
itions) and pager-level policies (what is actually done in
practice).
Does this seem like a reasonable idea? More importantly,
will it work (not break SQLite)?
Thanks,
Richard Klein
.
Do I have this right?
Thanks,
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
!;-)
Thanks,
Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
error. Typically he will want to sleep for a little while,
and then try again.
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
?
Thanks,
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
or
indirectly) to the PENDING or EXCLUSIVE state,
and since it doesn't prevent other processes
from acquiring SHARED locks, what is it good
for?
Thanks in advance,
- Richard Klein
-
To unsubscribe, send email to [EMAIL
Joe Wilson wrote:
--- Richard Klein [EMAIL PROTECTED] wrote:
I am seeing SQLite crashing during execution
of a SELECT statement when I make the page
cache very small (40 pages).
When I bump the cache up to 50 pages, the
problem goes away.
The problem only occurs on my RISC platform,
not on my
.
http://www.sqlite.org/cvstrac/wiki?p=ScrollingCursor
--
D. Richard Hipp [EMAIL PROTECTED]
Very clear and useful article. Thanks!
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
]
Thanks for your replies, Richard and Joe. You've
convinced me to take a closer look at the memory
footprint of SQLite 3. I'll let you know what I
find.
- Richard Klein
-
To unsubscribe, send email to [EMAIL PROTECTED]
-
(not 3).
My RISC platform prints out the stack trace
in hex, not program symbols, so I can't yet
tell you where in SQLite I'm crashing. (I'll
try to get more info from the vendor on how
to use their debugger.)
Anyone ever see anything like this?
Regards,
- Richard Klein
Hello,
I am evaluating sqlite 2.x for use in an embedded
system in which the maximum number of simultaneously
open files is severely limited.
To be precise, only 32 files can be open at the same
time system-wide; of these, only 8 can be application
level files. I need to ensure that this is
Richard Klein [EMAIL PROTECTED] wrote:
(Reminder: I am using sqlite version 2.x.)
Why? SQLite 3 is faster, more robust, and much better
and not opening unnecessary files.
--
D. Richard Hipp [EMAIL PROTECTED]
I would love to upgrade to SQLite 3. Unfortunately,
it is too big for our
1 - 100 of 111 matches
Mail list logo