Re: [sqlite] Performance problems and large memory size

2010-09-22 Thread Max Vlasov
cked it), there's just an advice on the site wiki to change it to the cluster size immediately after the db creation ( http://www.sqlite.org/cvstrac/wiki?p=PerformanceTuningWindows). Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://s

Re: [sqlite] Strange cache behavior

2010-09-22 Thread Max Vlasov
he_size. For default sqlite cache size it's rereading of 2M to 3M tables. Not so great disadvantage to change the algorithm. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] Strange cache behavior

2010-09-22 Thread Max Vlasov
ilar tests with other front-ends. If someone really interested, I can upload my tool, but it's just not completely ready for mainstream. Thanks, Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] grouping inserts vs. one large tranaction

2010-09-19 Thread Max Vlasov
f the field, a separated hash could give you speed increase if an average size of your hash entry much smaller than the size of your name field and you don't expect many collisions (since in case of collision you still have to access the original name field that actually kills your attempt to

Re: [sqlite] VACUUM can actually increase the DB file?

2010-09-18 Thread Max Vlasov
egrity_check; Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] returning smaller subset of columns: index vs trigger

2010-09-11 Thread Max Vlasov
can be a separated table with sing field id (rowid) that should > change > > its contents synchronously to the main table that contains all data. I > > suppose in this case the two variants (index vs trigger) is on par in > terms > > of the size or am I wrong? > >

Re: [sqlite] is there a program that converts sqlite database from windows-1252 to utf-8 ?

2010-09-11 Thread Max Vlasov
> > is there a program that converts sqlite database from windows-1252 to utf-8 > ? > It the base is not big, I think you can dump the db to sql file with the sqlite shell, convert this text file to UTF-8 (even with notepad) and feed it to

Re: [sqlite] reading directly from indices (was: returning smaller subset of columns: index vs trigger)

2010-09-11 Thread Max Vlasov
On Sat, Sep 11, 2010 at 10:26 PM, Drake Wilson wrote: > Quoth Max Vlasov , on 2010-09-11 22:16:14 +0400: > > although index at least should not be worse in any situation > > I wouldn't be quite so sure. Would there not be use cases in which > different sets of columns

Re: [sqlite] returning smaller subset of columns: index vs trigger

2010-09-11 Thread Max Vlasov
I suppose in this case the two variants (index vs trigger) is on par in terms of the size or am I wrong? Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] returning smaller subset of columns: index vs trigger

2010-09-11 Thread Max Vlasov
tioned is TEXT and it's much more larger than all other fields together,the benefits of using the index for retrieval are not so great, although index at least should not be worse in any situation Max ___ sqlite-users mailing list sqlite-users@sqlite.o

Re: [sqlite] returning smaller subset of columns: index vs trigger

2010-09-11 Thread Max Vlasov
On Sat, Sep 11, 2010 at 2:05 PM, Cory Nelson wrote: > On Sat, Sep 11, 2010 at 12:36 AM, Max Vlasov wrote: > > Hi, > > > > What other observations can be made about these two types of solutions > that > > I may face in the future? > > Both are commonly used

[sqlite] returning smaller subset of columns: index vs trigger

2010-09-11 Thread Max Vlasov
t for other db engines. What other observations can be made about these two types of solutions that I may face in the future? Thanks, Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-10 Thread Max Vlasov
is case since a chance of a power or system failure is higher and higher each day :) Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-10 Thread Max Vlasov
main db file and shm file is the way to find those pages for readers and for pager to commit them. The shm file could be hungry for memory, but it's not a big deal since it's always wants 128 times less then the size of the data changed. Max ___

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-10 Thread Max Vlasov
l processor architecture pages) in 386-adress space. The actual error appears after the MapViewOfFile call and the text is 'Not enough storage is available to process this command' (Code: 9) Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-10 Thread Max Vlasov
qlite3_sqlite3_f213e133f6.zip I kind of injected modified os_win.c from the full package into 3_7_2 amalgamation. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-10 Thread Max Vlasov
c that requires this, but on Windows 350 regions is a maximum in this case. Does it mean that linux share address space for superset/subset regions in contrary to Windows logic? Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-09 Thread Max Vlasov
e queries are executed, when the shm file grows to 11M (0xAC), the failure occurs with Disk I/O error (both result and extended are 10 (SQLITE_IOERR)). There's a change that there's something wrong with my program, can someone do a similar test

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-09 Thread Max Vlasov
to the absence of free space. The size of shm file is 0xAC, and the section starting 0xAB8000 till the end filled with zeros. Please let me know if anything would be helpful to know from these files, I keep it in the state they were after the failure, I even did not perform Commit and Close. Max _

Re: [sqlite] memory wasted shm mapped file (3.7.2)

2010-09-09 Thread Max Vlasov
could not reproduce this when the db is already in WAL mode when opened. Michele, can you tell us what is the mode when you initially open db? Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Detecting storage class from C

2010-09-08 Thread Max Vlasov
for the given type and when the result of sqlite3_column_type (actual type of a 'cell') doesn't compatible with this list, I will show some warning about this result set. Max, maxerist.net ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Trigger Questions

2010-09-02 Thread Max Vlasov
d aesthetics, but leads to bad cases like this. Sure it's too late to change anything in the SQL, I just wish the creators changed "SET=" to "SET TO"... Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] upstreaming Chromium patches for file handle passing support

2010-09-01 Thread Max Vlasov
ace you prefer a temporal file. I know it looks a little stange, but can someone confirm this approach at least works? Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Feature request: copying vacuum

2010-09-01 Thread Max Vlasov
t raw partition sqlite in days if one _really_ needs it :) I wonder whether someone already did it at least for one OS. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Feature request: copying vacuum

2010-09-01 Thread Max Vlasov
red about the reasons why is implemented the way it is. You can read it here: http://www.mail-archive.com/sqlite-users@sqlite.org/msg50941.html Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] next value in sequence

2010-08-31 Thread Max Vlasov
On Tue, Aug 31, 2010 at 9:07 AM, Eric Smith wrote: > > You probably don't want 'SELECT max(foo_id)+1' because I think that does > a full table scan. > > you're right, but slightly modified version SELECT (SELECT max(foo_id)

Re: [sqlite] Sqlite on NAND flash devices...

2010-08-30 Thread Max Vlasov
work perform INSERT INTO MyMainTable SELECT * FROM MyTempTable. So this is the query that actually affects the contents of the main db (and writes also to the journal file). This one can be interrupted with a power failure and in this case on a next open sqlite will try to restore the state that wa

Re: [sqlite] Sqlite on NAND flash devices...

2010-08-30 Thread Max Vlasov
ent storage every 2 minutes is ok since if it's a transaction, sqlite will take care of the power loss consequences regardless of whether it's a single insert or multiply from a temporal table Max ___ sqlite-users mailing list sqlite-users@sqlite

Re: [sqlite] Is there a design doc for the virtual machine re-write?

2010-08-30 Thread Max Vlasov
y fraction of time (for example when the page is already in the cache), this might affect the performance in general. Also you can try to compare EXPLAIN QUERY result from a version prior to 3.5.5 to some of the current one for the same sql query. I wanted to do this myself, but seems like can not acc

Re: [sqlite] Implementation check request

2010-08-28 Thread Max Vlasov
o you have reason to think that it should go to the end? Max On Sat, Aug 28, 2010 at 7:03 PM, Simon Slavin wrote: > Can someone check the source code for me ? Or perhaps this can be found > from a query plan or something. > > A current discussion reminded me that something w

Re: [sqlite] implementing a row cache

2010-08-28 Thread Max Vlasov
E Word < 'TAKE' ORDER BY Word DESC LIMIT 100) UNION SELECT * FROM (SELECT * FROM MxVft_FTWords WHERE Word >= 'TAKE' ORDER BY Word LIMIT 100) ORDER BY Word I tried it on a real table containing about 1,3M records, EXPLAIN QUERY PLAN successfully reported about index usage, al

Re: [sqlite] partial index?

2010-08-21 Thread Max Vlasov
able scan. > > If your csv inserts are made as a whole, what about keeping track of rowid ranges (rowidfrom..rowitto) for every csv insert in a separate table? You can be sure it will be a new range not intersecting with any previous if rowid is AUTOINCREMENT (or you can provide your own id s

Re: [sqlite] Can we get a pragma for SQLITE_FCNTL_CHUNKS_SIZE?

2010-08-20 Thread Max Vlasov
as cases like yours is real and can be used in real life, maybe a change to existing freelist_count pragma is possible? If it is writable (PRAGMA freelist_count=1024;), sqlite compares the value supplied with the current count and if it is bigger allocates necessary space. It seems this syntax

Re: [sqlite] Can we get a pragma for SQLITE_FCNTL_CHUNKS_SIZE?

2010-08-19 Thread Max Vlasov
d the docs says there's no guarantee the syntax will not change and the results will be the same (The recent WAL-related changes to journal_mode is a good example). In case of api calls, we at least have compiler's errors and warnings. Max

Re: [sqlite] Can we get a pragma for SQLITE_FCNTL_CHUNKS_SIZE?

2010-08-19 Thread Max Vlasov
me specific cases and if it gets its own pragma it will just add confusion. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Sizeof tables

2010-08-18 Thread Max Vlasov
Look at this discussion: http://www.mail-archive.com/sqlite-users@sqlite.org/msg53997.html at least two variants of the solution there. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Same db, same query, very slow query performance in sqlite 3.7.0.1

2010-08-16 Thread Max Vlasov
problem, but it seems the cause was different to one mentioned by you. When I narrowed the query to select * from catalogues inner join (select max(validfrom), idcatalogue from CRONOcatalogues) as tbl on catalogues.idcatalogue=tbl.idcatalogue and catalogues.active='s' The differe

Re: [sqlite] Reserve database pages

2010-08-13 Thread Max Vlasov
On Fri, Aug 13, 2010 at 1:38 PM, Max Vlasov wrote: > > I can approximately calculate, how big the new database will grow. Is >> there a way to tell SQLite to reserve an inital space or numer of pages >> instead of letting the database file grow again and again? >>

Re: [sqlite] Reserve database pages

2010-08-13 Thread Max Vlasov
From what I see, it seems that the sqlite internally doesn't rely on the file size for the core functionality and xFileSize looks more like a service function, but I may be wrong Max Vlasov, www.maxerist.net ___ sqlite-users mailing list sqlite-user

Re: [sqlite] Coping with database growth/fragmentation

2010-07-28 Thread Max Vlasov
qlite expects. So before any file system defragmentation, internal sqlite defragmentation (VACUUM) have to be applied. Max Vlasov, maxerist.net ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] VACUUM not reclaiming space

2010-07-27 Thread Max Vlasov
elated to some encoding conversion, like UTF16 in first case and UTF-8 in the other? Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] suggestion: bitwise shift right optimization

2010-07-20 Thread Max Vlasov
ing db right before you with all the statistics available encourages experimenting opposite to for example mysql looking like a mountain far away ) Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Horrendous slowdown when updating versions

2010-07-20 Thread Max Vlasov
ovide more details about the query, maybe narrow it to some easily understandable sql fragment Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] suggestion: bitwise shift right optimization

2010-07-20 Thread Max Vlasov
ind any value and after that move left while F() is true and move right while F() is true. On the other size this kind of search will have either the same effectiveness as a full scan (in worst case) or better. I suppose this limitation is also why the queries with complex left parts (even

Re: [sqlite] error in sum function

2010-07-20 Thread Max Vlasov
If the user does not want it, ok, select "never show again" and forget about it, but personally I'd never switch it off. Sure it's not a problem for tools that always use sqlite3_bind_text for display purpuses. Max ___ sqlite

[sqlite] suggestion: bitwise shift right optimization

2010-07-20 Thread Max Vlasov
when several small fields exists and they should be indexed, one can pack them into id(rowid) to save space and the first syntax will allow querying more naturally Thanks, Max Vlasov maxerist.net ___ sqlite-users mailing list sqlite-users@sqlite.org http

Re: [sqlite] How much a table takes (will this query always work)

2010-07-17 Thread Max Vlasov
; > If I'm asked, the syntax PRAGMA page_count(table_name/index_name) would be great if such function could be included in future versions. And the old syntax without names would work as before Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] How much a table takes (will this query always work)

2010-07-17 Thread Max Vlasov
e corresponding functions in the c source and make them public, right? Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] How much a table takes (will this query always work)

2010-07-16 Thread Max Vlasov
abase before)? - Such method is not good for large databases since all the data should be re-saved just to get the value. If someone suggest an algorithm solving this, this will be great. Thanks, Max ___ sqlite-users mailing list sqlite-users@sqlite.org htt

Re: [sqlite] error in sum function

2010-07-14 Thread Max Vlasov
e rows with such values Max On Wed, Jul 14, 2010 at 2:43 PM, Riccardo Cohen wrote: > Hello > I've been using sqlite in many projects (thanks for providing it) and > found today someting strange with sum function > > I have a simple database: > > CREATE TABLE data (irisid

Re: [sqlite] New 3.7.0 snapshot - release estimated for July 22

2010-07-14 Thread Max Vlasov
sqlite3_file*); int (*xShmLock)(sqlite3_file*, int offset, int n, int flags); int (*xShmMap)(sqlite3_file*, int iPage, int pgsz, int, void volatile**); (201007140820) int (*xShmMap)(sqlite3_file*, int iPg, int pgsz, int, void volatile**); int (*xShmLock)(sqlite3_file*, int offset, in

Re: [sqlite] WAL: no longer able to use read-only databases?

2010-07-13 Thread Max Vlasov
on it's ok, WAL already has special conditions on which it would operate and the current documentation describes them all thoroughly. I wish only the "advantages" sections of WAL also grew a little, maybe giving more details about speed impr

Re: [sqlite] Suggestion for sqlite shell

2010-07-12 Thread Max Vlasov
rse csv content, I think this feature will require no more than a couple of hundred lines of code Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] Suggestion for sqlite shell

2010-07-12 Thread Max Vlasov
ignoring extra fields with padding. I don't know whether the clipboard content can be used in sqlite ideologically, but in my case it saved additional time allowing importing for example from excel without the intermediate file (csv). Thanks Max Vlasov www.maxeris

Re: [sqlite] How to determine when to VACUUM?

2010-07-08 Thread Max Vlasov
thing to research especially in sqlite perspective, for example, for reading it's access times that makes SSD winner, so probably reading large sqlite database randomly can have some benefits being used on SSD, but I don't know of any real world measurements. Do you know any? Max

Re: [sqlite] WAL questions

2010-07-08 Thread Max Vlasov
in WAL mode and the last reader/writer that closes the base, reverts it back (=1) allowing the file format stays the same. Sure there are possible cases when the format still changed (for example unexpected program end), but the next successful open/close will fix this. Max __

Re: [sqlite] WAL questions

2010-07-08 Thread Max Vlasov
a potential way of new wave of mass bug/missing reporting or simply confusion I may exaggerate, I suggest other participants of the list share their thoughts Thanks, Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] How to determine when to VACUUM?

2010-07-08 Thread Max Vlasov
stem in Windows is still not smart enough even for much easier SSD-related tasks :) Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] WAL questions

2010-07-07 Thread Max Vlasov
al", ok 3. Close the database. offsets 18,19 still = 2, so the WAL setting are kept between sessions. 4. Open the db again, offsets 18,19 still = 2, query PRAGMA journal_mode; it says "delete", but definetely should return "wal". Max On Thu, Jul 8, 2010 at 12:09 AM,

[sqlite] WAL questions

2010-07-07 Thread Max Vlasov
07060929.zip - About vfs. Is it ok to implement version 2 of the interfaces and supply it to older versions? So if the structures contain iVersion=2, will all prior versions of sqlite3 accept it? Thanks, Max, maxerist.net ___ sqlite-users mailing list sql

Re: [sqlite] Why "select count(distinct f1, f2) from tbl_test" can not work?

2010-06-26 Thread Max Vlasov
s like this select count(distinct ((Value1 << 32) | Value2)) FROM TestTable but I did quick text for a table consisting of thousands of integers, the speed is similar to your another query that you called not very good. I think both needs some temporary stor

Re: [sqlite] database corruption problem

2010-06-08 Thread Max Vlasov
domly and writing randomly until specially interrupted. While the program reads and writes you check PRAGMA integrity_check; from time to time and stop if result shows corruption. If you can't reproduce the problem on your machine you can send specially prepared version to the user an

Re: [sqlite] Is the absence of msvcrt.dll a known issue with SQLite Windows 2000

2010-06-06 Thread Max Vlasov
he sources (if it had, this can be some indication of dynamic dependency). Max, maxerist.net ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] Returning empty result set

2010-06-01 Thread Max Vlasov
se a query working in both worlds: SELECT * FROM (SELECT 1) AS TBL WHERE 1=2 ? Thanks Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] SQLite turns 10 years old

2010-05-29 Thread Max Vlasov
e packages. If I had power, I'd be glad to calculate and see how many sqlite-related reads and writes are taking place on the whole earth. I'm sure it's a big number :) Thank you for sqlite! Max Vlasov On Sat, May 29, 2010 at 5:57 PM, D. Richard Hipp wrote: > > Thanks, everyb

Re: [sqlite] Aggregate and join query very slow

2010-05-27 Thread Max Vlasov
ear field), this will lead to full table reading (so all the data of your 4M records). If it's properly indexed, and the result number of records of this select is big, consider adding non-indexed fields to this (or brand-new) index since otherwise sqlite quickly finds records with this index,

Re: [sqlite] Does sqlite always allow creating own field named 'rowid'?

2010-05-26 Thread Max Vlasov
queness limitation on its own rowid field, we could see repeating values or even non numeric values. I think that using _rowid_ might be additional guarantee from such problems, but I suppose many developers still prefer rowid. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] Does sqlite always allow creating own field named 'rowid'?

2010-05-26 Thread Max Vlasov
wondering, was allowing to create such field intentional? As I suppose such field is complete phantom since most sql queries will interpret rowid internally and won't allow access this user field at all. Max ___ sqlite-users mailing list sqlite-

Re: [sqlite] Update detail record based on master properties

2010-05-26 Thread Max Vlasov
masterfieldtocheck = okvalue and >masterfield2tocheck = okvalue2); > > -- > Igor Tandetnik > > Thanks,Igor, it works, I see that sql itself is smart enough ) Both suggested by you are similar in speed, but the latter looks more self-explanatory for me. Max _

[sqlite] Update detail record based on master properties

2010-05-26 Thread Max Vlasov
similar select statement in the second section, is sqlite optimizer smart enough to recognize that the both parts queries the same record and not to perform this operation several times? Thanks Max, maxerist.net ___ sqlite-users mailing list sqlite-users

Re: [sqlite] What languages can include SQLite statically?

2010-05-24 Thread Max Vlasov
available on aducom.com, but the version I used had a serious bug, Albert (from aducom.com) promised to fix on the site, probably you can use it as of now. Max maxerist.net On Fri, May 21, 2010 at 1:31 PM, Gilles Ganault wrote: > Hello > > My C skills are very basic. I was wonderi

Re: [sqlite] Loading Sqlite3 DB into memory

2010-05-20 Thread Max Cat
entation on it, either.) Thanks again! :) -Max --- On Thu, 5/20/10, Pavel Ivanov wrote: From: Pavel Ivanov Subject: Re: [sqlite] Loading Sqlite3 DB into memory To: "General Discussion of SQLite Database" Date: Thursday, May 20, 2010, 5:13 AM You can write your own VFS and then u

[sqlite] Loading Sqlite3 DB into memory

2010-05-20 Thread Max Cat
e for your help! :) -Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Id ranges to be used with joins

2010-05-07 Thread Max Vlasov
anges > on (MyTable.id between IdFrom and IdTo); > Yes, thanks, Igor, Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] Id ranges to be used with joins

2010-05-07 Thread Max Vlasov
a way to use them in joins directly, but if it's not possible, at least to find an effective way to populate this ranges to a temporary table. I know there's a always a way to do this algorithmically, but just wondering if it's possible with sql. Thanks, Max Vlas

Re: [sqlite] Exclusive transactions over network

2010-04-28 Thread Max Vlasov
writes from several computers you will at least have probability arguments on your side ) Max Vlasov, maxerist.net On Wed, Apr 28, 2010 at 9:43 AM, Jean-Christophe Deschamps wrote: > Hi gurus, > > I'm aware of the limitations that generally preclude using SQLite over > a network

Re: [sqlite] Direct access of table data

2010-04-23 Thread Max Vlasov
l the data from the index itself saving time and the amount of data flow. I did a quick test and it showed not only a noticable difference in time, but also a significant difference in amount of the data read. Max, maxerist.net ___ sqlite-users mailing lis

Re: [sqlite] Please help test the latest query planner changes

2010-04-16 Thread Max Vlasov
o exclude windows system cache as a player. Max Vlasov, maxerist.net ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Sharing an SQLite database (using whole-file locking) over OpenAFS (Andrew File System)

2010-04-12 Thread Max Vlasov
** A PENDING_LOCK is obtained by locking a designated byte different from ** the RESERVED_LOCK byte. It was a note about windows, but there's also a phrase "The same locking strategy and byte ranges are used for Unix." Max Vlasov, maxerist.net _

Re: [sqlite] fast acces to one memory located table from two threads

2010-03-24 Thread Max Vlasov
kes no sense. But you probably can work around this with your own mutexes, wrapping your calls in the corresponding access/release calls, but I suppose there still could exist some complexities. I didn't try it myself, but I guess there are some operations that can be implemented safely wi

Re: [sqlite] fast acces to one memory located table from two threads

2010-03-24 Thread Max Vlasov
y part of the base (fast appending), another one will do necessary selects and inserts to disk db part. After the db is closed, you will only have disk part left. I don't know more about locking logic in this case, because for performance reasons, it would be better for example, if memor

Re: [sqlite] INTERSECT versus INNER JOIN with latitude, longitude queries

2010-03-22 Thread Max Vlasov
need it, but if you have tow compact indexes indexes only by X and Y, and use intersect the data flow will be the same regardless of your record size. In my test case, if I'd added descriptions to the table and every description were 1000 bytes, the final size would grow from 44M to 1G

Re: [sqlite] INTERSECT versus INNER JOIN with latitude, longitude queries

2010-03-21 Thread Max Vlasov
the latter reads about 3M of data from this 44M base (so no full table scan) You say that your INNER JOIN QUERY faster? You probably have a different scheme, maybe that's the reason, but please let us know in this case Max ___ sqlite-users mai

Re: [sqlite] INTERSECT versus INNER JOIN with latitude, longitude queries

2010-03-21 Thread Max Vlasov
; the background of my question: > > Tim, maybe drh answer on my question regarding INTERSECT could help? http://www.mail-archive.com/sqlite-users@sqlite.org/msg49646.html Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sql

Re: [sqlite] VACUUM & journal size

2010-03-17 Thread Max Vlasov
l too), you gave a very detail description of the situation. Although unlikely your interesting suggestion (VACUUM TO) will be implemented, I think one always make his own equivalent if it is necessary (creating a subset of operations from sqlite3RunVacuum) Max __

Re: [sqlite] VACUUM & journal size

2010-03-16 Thread Max Vlasov
about sqlite3RunVacuum that it needs more space than a simple emulation of its actions? Thanks Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] FTS3 (Version 2 .6.23) - Is the boolean operator "AND" no more available?

2010-03-15 Thread Max Vlasov
SIS This option modifies the query pattern parser in FTS3 such that it supports operators AND and NOT (in addition to the usual OR and NEAR) and also allows query expressions to contain nested parenthesesis. Max ___ sqlite-users mailing list sqlite-us

Re: [sqlite] Can default column values use max() ?

2010-03-15 Thread Max Vlasov
or, Title) VALUES ((Select Max(rowid) FROM Authors), "test") just worked (tested it), sure you have to make id autoincrement to ensure Max(rowid) is actually the last author Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqli

Re: [sqlite] [sqlite-dev] Poor SQLite indexing performance

2010-03-15 Thread Max Vlasov
ust enumerating records building the tree. CMIIW Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] structure question

2010-03-14 Thread Max Vlasov
done in order to reverse changes. So you could create your own log table inside your sqlite base logging your changes.It works if all the changes is controlled by you, so before any DELETE, INSERT, UPDATE you can prepare this information and write

[sqlite] Column types "safe" changes

2010-03-10 Thread Max Vlasov
like moving from INTEGER to TEXT? Also is it possible to add to sqlite a limited ALTER TABLE .. MODIFY support that could wrap all known "safe" changes and invoking errors on all "unsafe" ones? Max ___ sqlite-users mailing list sql

Re: [sqlite] non-blocking concurrent read questions

2010-03-09 Thread Max Vlasov
y reads. In this case reader and write don't have strict requirements about locking (at least the reader can be more important in this case). You can tune their relationship in a way when raw writer and sqlite writer are usually synchronized, but if the reader is more active there are temporary m

Re: [sqlite] non-blocking concurrent read questions

2010-03-09 Thread Max Vlasov
ot; error. Instead consider changing your own logic. You wrote "without* any possibility to be blocked". I suppose you already have a perfect writer that fits your needs, but if you post some info about the nature of your writer and reader (records pe

Re: [sqlite] Maximum database size?

2010-03-03 Thread Max Vlasov
u have enough time, I'd do this before anything else Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] A question about sqlite : How could i get the rows affected by current sql statement ?

2010-03-02 Thread Max Vlasov
ote from the docs: This function returns the number of row changes caused by INSERT, UPDATE or > DELETE statements since the database connection was opened. > Either you're or this sentence on the site should be changed (in the final part) Max

Re: [sqlite] A question about sqlite : How could i get the rows affected by current sql statement ?

2010-03-02 Thread Max Vlasov
ffected and simple SELECT afterward, this call will still return 2. In this case I'd recommend using difference between consequitive sqlite3_total_changes() values. For any read-only query this difference will always be zero. Max ___ sqlite-users mailing lis

Re: [sqlite] FTS & Doc Compression

2010-03-02 Thread Max Vlasov
ndexing the size has changed to 1,5G. And I even didn't use stop-words. So with proper stop-words usage the ratio can even be better. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] BLOBs' affect on DB performance

2010-03-02 Thread Max Vlasov
ves just indexes (based on anything but your blobs) and these blobs are accessed on some final stage of the query, go with blobs inside sqlite base. Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] accessing file change counter in api

2010-02-27 Thread Max Vlasov
core functionality. What you think? Maybe such addition is too specific? Thanks Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Prepared statements and locking

2010-02-26 Thread Max Vlasov
tion will be included in the article about sqlite3_reset some day, Thanks Max ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

<    1   2   3   4   5   >