Re: [sqlite] Stored Procedures

2018-05-14 Thread Warren Young
On May 14, 2018, at 9:44 PM, Alek Paunov wrote: > > Practical example of the benefit is that e.g. same complex turnover report > which implementation includes bunch of intermediate calculations, could be > used with same SQL call from Python desktop application, directly as

Re: [sqlite] Stored Procedures

2018-05-14 Thread hwoody2wood
I missed stored procedures till i coded my workaround. I had a table named sprocs with the sql statements coded into a text blob in each row with each row representing a different sproc. A linked table named params had a column with a tag representing a parameter for the associated sproc. Pull

Re: [sqlite] Stored Procedures

2018-05-14 Thread Alek Paunov
On 2018-05-09 03:56, Richard Hipp wrote: ... The other benefit of stored procedures is that it provides a way to code up a common operation once (correctly!) and store it in the database, rather than having multiple clients all have to work out the operating themselves (some of them perhaps

Re: [sqlite] Problem b building sqlite on macOS android.

2018-05-14 Thread Cezary H. Noweta
Hello, On 2018-05-15 02:59, Jens Alfke wrote: On May 12, 2018, at 12:35 PM, Mark Sibly wrote: I am having problems building sqlite with the android NDK for macos. The problem is actually with the ioctl.h header, nothing specific to SQLite. Simply, try to define

Re: [sqlite] Problem b building sqlite on macOS android.

2018-05-14 Thread Jens Alfke
> On May 12, 2018, at 12:35 PM, Mark Sibly wrote: > > I am having problems building sqlite with the android NDK for macos. The problem is actually with the ioctl.h header, nothing specific to SQLite. Make sure you're using the correct compiler for the NDK, because it

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Keith Medcalf
Yes, and why do you need to do that? (Use multiple connections to the same read only data)? --- The fact that there's a Highway to Hell but only a Stairway to Heaven says a lot about anticipated traffic volume. >-Original Message- >From: sqlite-users [mailto:sqlite-users-

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Abroży Nieprzełoży
AFAIK the only way to access single memory database from multiple connections is through shared cache. 2018-05-15 0:27 GMT+02:00, Keith Medcalf : > >>2018-05-13 12:50 GMT+02:00, Techno Magos : > >>> Hello > >>> I do not have clear examples to post on this but would like to

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Keith Medcalf
>2018-05-13 12:50 GMT+02:00, Techno Magos : >> Hello >> I do not have clear examples to post on this but would like to >> report findings around multi threaded read access (single process) in a >> large system that uses sqlite. >> This may be a known issue/restriction of memory sqlite

Re: [sqlite] fail building snapshot 201805081303

2018-05-14 Thread Michele Dionisio
Hi, my build system is quite complicated because I'm building sqlite using yocto for my embedded device. The build machine is quite old (ubuntu 12.04 x86). The sqlite build (with autoconf) correctly end but the problem is that any program that is linked to sqlite and is not compiled with

Re: [sqlite] Stored Procedures

2018-05-14 Thread Richard Hipp
On 5/14/18, Warren Young wrote: > > Your benchmark doesn’t address the primary problems pointed out in the > Mozilla article: The point of my article is that many people assume *without measuring* that reading and writing directly to the filesystem will be faster than using a

Re: [sqlite] Stored Procedures

2018-05-14 Thread Warren Young
On May 14, 2018, at 1:19 PM, Richard Hipp wrote: > > On 5/14/18, Warren Young wrote: >> >> https://wiki.mozilla.org/Performance/Avoid_SQLite_In_Your_Next_Firefox_Feature > > That's an older article. These days, it is generally faster to use > SQLite than

Re: [sqlite] Stored Procedures

2018-05-14 Thread Richard Hipp
On 5/14/18, Warren Young wrote: > > https://wiki.mozilla.org/Performance/Avoid_SQLite_In_Your_Next_Firefox_Feature > That's an older article. These days, it is generally faster to use SQLite than fopen(). See, for example, https://www.sqlite.org/fasterthanfs.html -- D.

Re: [sqlite] Stored Procedures

2018-05-14 Thread Warren Young
On May 13, 2018, at 10:15 PM, Rowan Worth wrote: > > ...I wouldn't call the extra i/o imposed by sqlite "very very > cheap" either - it doubles writes (once to the rollback journal, once to > the DB), forces syncs, and likely results in a more seek heavy i/o pattern > (this

Re: [sqlite] question about DB

2018-05-14 Thread Paul Sanderson
Try it in a command line shell with the timer on .timer on Paul www.sandersonforensics.com SQLite Forensics Book On 14 May 2018 at 17:27, Simon Slavin wrote: > On 14 May 2018, at 3:03pm, sebastian bermudez

Re: [sqlite] question about DB

2018-05-14 Thread Simon Slavin
On 14 May 2018, at 3:03pm, sebastian bermudez wrote: > the question is, there are some order of penalty in attach (2+) databases vs > one big DB ? Three databases of 2.4Gb size ? SQLite is designed to expect this. Slow down for attaching compared with one big

Re: [sqlite] Stored Procedures

2018-05-14 Thread Abroży Nieprzełoży
> That's fair, but I wouldn't call the extra i/o imposed by sqlite "very very > cheap" either - it doubles writes (once to the rollback journal, once to > the DB), forces syncs, and likely results in a more seek heavy i/o pattern > (this depends a bit on schema design and whether the app

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Richard Hipp
On 5/13/18, Abroży Nieprzełoży wrote: > Try to open N separate database connections (without shared cache) and > load content using sqlite3_deserialize with > SQLITE_DESERIALIZE_READONLY flag. > http://www.sqlite.org/c3ref/deserialize.html > SQLite won't copy

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Peter Da Silva
On 5/14/18, 9:17 AM, "sqlite-users on behalf of Bernard Ertl" wrote: Apologies if I muddled the waters here. I read the "SQLightning" response below as SQLitening. I didn't know there was a similarly

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Bernard Ertl
Apologies if I muddled the waters here. I read the "SQLightning" response below as SQLitening. I didn't know there was a similarly named project out there. I also can't see the beginning of this discussion to have context on what was originally asked, so I don't know which project was

[sqlite] question about DB

2018-05-14 Thread sebastian bermudez
I need to know if there are some order of penalty in attach (2+) databases to make a small (3 tables) join... (one table per DB). vs. (3 tables on same DB). I need it to get a small order concurrency writes... I have 3 process writting to one to each DB. but i need query everithing

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Peter Da Silva
Now I'm even more confused, there's "sqlightning" and "sqlitening". Are these different names for the same project? It doesn't seem so. Which was intended? https://github.com/LMDB/sqlightning On 5/14/18, 8:47 AM, "sqlite-users on behalf of Bernard Ertl"

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Bernard Ertl
This is the latest: http://www.sqlitening.planetsquires.com/index.php?topic=9427.0 I contributed to the last SQLitening update. No one has reported any issues that need fixing or updating since that update. It seems to be working quite well/stable. > On 5/13/18, 6:48 AM, "sqlite-users on

Re: [sqlite] shell edit quoting

2018-05-14 Thread Peter Da Silva
I think you're in "csv mode": sqlite> select sql from sql_procs where name = 'a'; select * from "mytable" ; sqlite> .header on sqlite> .mode csv sqlite> select sql from sql_procs where name = 'a'; sql "select * from ""mytable"" ; " On 5/13/18, 7:04 PM, "sqlite-users on behalf of David Burgess"

Re: [sqlite] Multi threaded readers on memory sqlite cannot scale

2018-05-14 Thread Peter Da Silva
On 5/13/18, 6:48 AM, "sqlite-users on behalf of Howard Chu" wrote: SQLightning Do you have a link to the currently updated version of this? Google gives me projects that haven't been updated since 2015.

Re: [sqlite] Again sqlite repository servers out of sync ?

2018-05-14 Thread Richard Hipp
On 5/14/18, Domingo Alvarez Duarte wrote: > Hello Richard ! > > It's now several days that I'm seeing one thing on > http://www.sqlite.org/src/timeline but when I try to update my cloned > repository I get stuck with this: I updated the fossil binary with a version that did

[sqlite] Again sqlite repository servers out of sync ?

2018-05-14 Thread Domingo Alvarez Duarte
Hello Richard ! It's now several days that I'm seeing one thing on http://www.sqlite.org/src/timeline but when I try to update my cloned repository I get stuck with this: fossil update Autosync:  https://www3.sqlite.org/cgi/src Round-trips: 1   Artifacts sent: 0  received: 0 Pull done,