[sqlite] VIsual Studio 2005. slow and high CPU in debug

2012-03-19 Thread Juan Perez
Hi all: I´m using SQLite amalgamation in various exe files with Visual Studio 2005. In debug mode the exe files are very slow and have high CPU usage. In release the problem dissapears. Is there some option in SQLite to avoid this problem? Thank you very much in advance.

Re: [sqlite] VIsual Studio 2005. slow and high CPU in debug

2012-03-19 Thread Larry Brasfield
Juan Perez wrote: Hi all: I'm using SQLite amalgamation in various exe files with Visual Studio 2005. In debug mode the exe files are very slow and have high CPU usage. In release the problem dissapears. Is there some option in SQLite to avoid this problem? You can change

Re: [sqlite] how can I disable all locking for max SELECT speed?

2012-03-19 Thread Dietmar Hofer
Grab the lock and never let go: http://sqlite.org/pragma.html#pragma_locking_mode -j That was exactly what I needed. I tried with file open flag SQLITE_OPEN_EXCLUSIVE before, but that seems to be something else. 40% faster now. Thanks a lot!

[sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread TAUZIN Mathieu
Hi, According to the documentation on SELECT statements http://www.sqlite.org/lang_select.html It seems possible to write join chains as A join (B join C). (using a '(' join-source ')' single-source ) But on the well known NorthwindEF database this query ... SELECT Orders.OrderID FROM

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Simon Slavin
On 19 Mar 2012, at 12:03pm, TAUZIN Mathieu mtau...@cegid.fr wrote: Or without subjoin... SELECT Orders.OrderID FROM Customers INNER JOIN Orders ON Customers.CustomerID = Orders.CustomerID LEFT OUTER JOIN InternationalOrders ON Orders.OrderID =

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread TAUZIN Mathieu
Thanks for your response but my intent was to give rise to either an bug on SQLite engine or an error (or maybe lack of precision) in the documentation. The sample I gave is a simplified version of the real query which is built by a tool so I have not the choice on the form. Mathieu.

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Pavel Ivanov
According to the documentation on SELECT statements http://www.sqlite.org/lang_select.html It seems possible to write join chains as A join (B join C). (using a '(' join-source ')' single-source ) ... It seems that parsing is ok (no syntax error) but sources in the sub join can't be used

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Simon Slavin
On 19 Mar 2012, at 12:51pm, TAUZIN Mathieu mtau...@cegid.fr wrote: Thanks for your response but my intent was to give rise to either an bug on SQLite engine or an error (or maybe lack of precision) in the documentation. SQLite is fine. The documentation is accurate about what SQLite does.

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Simon Davies
On 19 March 2012 13:05, Pavel Ivanov paiva...@gmail.com wrote: According to the documentation on SELECT statements http://www.sqlite.org/lang_select.html It seems possible to write join chains as A join (B join C). (using a '(' join-source ')' single-source ) ... It seems that parsing is

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread TAUZIN Mathieu
Thanks, This syntax works but it is not documented... it looks like a short hand for a subquery, interesting !. Mathieu -Message d'origine- De : sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] De la part de Simon Davies Envoyé : lundi 19 mars 2012 14:24 À :

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Nico Williams
On Mon, Mar 19, 2012 at 10:02 AM, TAUZIN Mathieu mtau...@cegid.fr wrote: Thanks, This syntax works but it is not documented... it looks like a short hand for a subquery, interesting !. Join sources are like sub-queries. Look at the syntax. A sub-select specified in the join-source

Re: [sqlite] VIsual Studio 2005. slow and high CPU in debug

2012-03-19 Thread Teg
Hello Juan, Debug mode is unusable for production code. Even it you add optimization, MS builds in a debug memory allocator/deallocator that's at least 10 times slower than the regular memory allocator. Running my application under debug, the memory allocations completely dominate

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Jay A. Kreibich
On Mon, Mar 19, 2012 at 12:03:44PM +, TAUZIN Mathieu scratched on the wall: Hi, According to the documentation on SELECT statements http://www.sqlite.org/lang_select.html It seems possible to write join chains as A join (B join C). (using a '(' join-source ')' single-source ) But on

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread TAUZIN Mathieu
Thanks for your support ! SQL Ansihttp://savage.net.au/SQL/sql-99.bnf.html#qualified%20join (and every major DB SqlServerhttp://msdn.microsoft.com/en-US/library/ms177634(v=sql.90).aspx, Oraclehttp://docs.oracle.com/cd/B13789_01/server.101/b10759/statements_10002.htm) supports this syntax as

Re: [sqlite] Join-source issue when using sub '(' join-source ')'

2012-03-19 Thread Ryan Johnson
On 19/03/2012 12:07 PM, TAUZIN Mathieu wrote: Thanks for your support ! SQL Ansihttp://savage.net.au/SQL/sql-99.bnf.html#qualified%20join (and every major DB SqlServerhttp://msdn.microsoft.com/en-US/library/ms177634(v=sql.90).aspx,

Re: [sqlite] Sqlite strange stack trace

2012-03-19 Thread LEVI HASKELL (BLOOMBERG/ 731 LEXIN)
Alexander, Just curious, how do you call Backup API from .NET (if you do)? AFAIK it's not accessible through System.Data.SQLite.dll. Did you have to compile SQLite separately from c sources? Thank you, - Levi - Original Message - From: sqlite-users@sqlite.org To:

[sqlite] R-Tree index not used when query has an ORDER BY clause

2012-03-19 Thread A Gilmore
Hello, My query wont use the R-Tree index if I provide an ORDER BY clause and performance degrades considerably. Obviously I can work around with by making the R-Tree query a subquery and sorting the results, but would like to know why this is necessary? I've done an VACUUM and ANALYZE.

[sqlite] sqlite and regexp on debian squeeze

2012-03-19 Thread prad
REGEXP requires definition of regexp() we seem to require C to do this: http://www.sqlite.org/lang_expr.html#regexp or apparently there is a sqlite3-pcre which adds /usr/lib/sqlite3/pcre.so and that does the trick. however, sqlite3-pcre doesn't seem to exist on debian. what is the

Re: [sqlite] sqlite and regexp on debian squeeze

2012-03-19 Thread prad
prad p...@towardsfreedom.com writes: REGEXP requires definition of regexp() we seem to require C to do this: http://www.sqlite.org/lang_expr.html#regexp or apparently there is a sqlite3-pcre which adds /usr/lib/sqlite3/pcre.so and that does the trick. however, sqlite3-pcre doesn't