Re: [sqlite] .exit in script is not working

2018-08-31 Thread Kees Nuyt
On Fri, 31 Aug 2018 19:29:47 +0200, Stéphane AULERY wrote: > When I use the -init option the .exit statement > at the end of my script is never executed. > > I launch sqlite from a batch file on Windows Server 2012 and Windows 7 64 bit. > > Command line : > sqlite3.exe -init myscript.scr If you

Re: [sqlite] Lemon Parser vs bubble-generator.tcl

2018-08-31 Thread Richard Hipp
On 8/31/18, Warren Young wrote: > They’re separate. Here’s the Tcl source for the bubble diagrams: > > https://www.sqlite.org/docsrc/file/?name=art/syntax/bubble-generator-data.tcl > > …and here’s the Lemon grammar for SQLite’s SQL parser: > > https://www.sqlite.org/src/file?name=src/parse.y

Re: [sqlite] Lemon Parser vs bubble-generator.tcl

2018-08-31 Thread Scott Robison
On Fri, Aug 31, 2018 at 2:59 PM Warren Young wrote: > > On Aug 31, 2018, at 1:55 PM, Scott Robison wrote: > > > > Is one generated from the other, or are they maintained separately? > > They’re separate. Here’s the Tcl source for the bubble diagrams: As I suspected having looked at them in the

Re: [sqlite] Lemon Parser vs bubble-generator.tcl

2018-08-31 Thread Warren Young
On Aug 31, 2018, at 1:55 PM, Scott Robison wrote: > > Is one generated from the other, or are they maintained separately? They’re separate. Here’s the Tcl source for the bubble diagrams: https://www.sqlite.org/docsrc/file/?name=art/syntax/bubble-generator-data.tcl …and here’s the Lemon

[sqlite] .exit in script is not working

2018-08-31 Thread Stéphane AULERY
Hello, When I use the -init option the .exit statement at the end of my script is never executed. I launch sqlite from a batch file on Windows Server 2012 and Windows 7 64 bit. Command line : sqlite3.exe -init myscript.scr myscript.scr : .log sqlite.log .bail off

[sqlite] Lemon Parser vs bubble-generator.tcl

2018-08-31 Thread Scott Robison
SQLite language as implemented uses a Lemon based parser. The syntax diagrams are created from the bubble-generator.tcl script. Is one generated from the other, or are they maintained separately? Is one (or another file that I don't know exists yet) the canonical description of the "complete"

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread t...@qvgps.com
Right. Was trying it out now, compiling some osm-dbs with primary key generated with this morton encoding from lat,lon and the performance is even worse. Debugging with the sqlite-tool shows, that the page counts for specific queries are almost double then before. Seems like, from the

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread Simon Slavin
On 31 Aug 2018, at 2:46pm, J Decker wrote: > There was a voxel engine that was claiming they were going to move to a > morton encoding; and I was working with a different engine, so I built a > simulator to test averge lookup distances; it was far more efficient to > keep sectors of voxels

Re: [sqlite] Best practices for forward conversion of database formats?

2018-08-31 Thread dmp
Randall wrote: ~ ~ > Any application that involves a "persistent" database, i.e., one where the data is > long-lived and expected to exist and evolve over time, sooner or later has the issue > of moving customers from a V1 database to a V2 database. Obviously at least one > technical issue (there

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread J Decker
On Thu, Aug 30, 2018 at 4:48 AM Richard Hipp wrote: > On 8/30/18, t...@qvgps.com wrote: > > > > Structure is simple: > > CREATE TABLE Lines(Id LONG PRIMARY KEY, Label VARCHAR(50), Coordinates > > BLOB, Flags INT, StyleId INT); > > And an rtree-index: > > CREATE VIRTUAL TABLE Lines_bb USING

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread Richard Hipp
On 8/31/18, t...@qvgps.com wrote: > Ok, then WITHOUT ROWID will most properly fit best in our use case. > Then I can fill the PRIMARY KEY with the z-order and store the osm-id > just in another column. I would think that your best approach is to make the INTEGER PRIMARY KEY be the Morton code

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread t...@qvgps.com
Ok, then WITHOUT ROWID will most properly fit best in our use case. Then I can fill the PRIMARY KEY with the z-order and store the osm-id just in another column. But do I still need to fill the table in the correct order according to z-order? I mean, we are talking about 1mio rows or so. At

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread Richard Hipp
On 8/31/18, t...@qvgps.com wrote: > > So is it just the value of the primary key controlling in which page the > row is stored? The page on which content is stored is determine (approximately) by the value of the ROWID, which is the same as the INTEGER PRIMARY KEY as long as you declare the

Re: [sqlite] Strategies to reduce page-loads?

2018-08-31 Thread t...@qvgps.com
> >(3) Consider deliberating choosing INTEGER PRIMARY KEY values based on >a "Morton code" or "Z-Order curve" of the coordinates. >(https://en.wikipedia.org/wiki/Z-order_curve) That will cause >features that are close together geographically to tend to be close >together within the file. My

Re: [sqlite] [O] A strange problem with org-babel and SQLite

2018-08-31 Thread Cecil Westerhof
Oops, wrong group. Sorry. :'-( 2018-08-31 12:21 GMT+02:00 Cecil Westerhof : > 2018-08-31 11:17 GMT+02:00 Robert Klein : > >> Hi Cecil, >> >> On Fri, 31 Aug 2018 10:47:50 +0200 >> Cecil Westerhof wrote: >> >> > I have a strange problem with org-babel and SQLite. >> > >> > I have a database that

Re: [sqlite] [O] A strange problem with org-babel and SQLite

2018-08-31 Thread Cecil Westerhof
2018-08-31 11:17 GMT+02:00 Robert Klein : > Hi Cecil, > > On Fri, 31 Aug 2018 10:47:50 +0200 > Cecil Westerhof wrote: > > > I have a strange problem with org-babel and SQLite. > > > > I have a database that is created with: > > CREATE TABLE "quotes" ( > > quoteID TEXT

Re: [sqlite] Best practices for forward conversion of database formats?

2018-08-31 Thread Ling, Andy
> This is not strictly a SQLite question, though in my case it is. > > Any application that involves a "persistent" database, i.e., one where the > data is long-lived and expected to exist and evolve over time, sooner or later > has the issue of moving customers from a V1 database to a V2

Re: [sqlite] beginners question

2018-08-31 Thread Klaus Maas
email signature Klaus Maas On 2018-08-30 21:39, Jürgen Palm wrote: Richard Hipp wrote: On 8/30/18, Jürgen Palm wrote: Richard Hipp wrote: On 8/30/18, Klaus Maas wrote: Same issues on Xubuntu 16.04 and 18.04 US