[sqlite] Sqlite incompatibility with Postgres

2016-05-15 Thread J Decker
On Sun, May 15, 2016 at 10:02 PM, Darren Duncan wrote: > On 2016-05-15 9:56 PM, J Decker wrote: >> >> On Sun, May 15, 2016 at 9:29 PM, Darren Duncan >> wrote: >>> >>> On 2016-05-15 12:35 AM, Simon Slavin wrote: All true. But it brings up a question. Suppose the following:

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Mikael
2016-05-15 22:23 GMT+07:00 Mikael : .. > Aha. > > Do you see any way that I could implement *one* layer of branches atop of > this? > > Say 1000 or 10^30 of them. > > Ah, make the selects for the timestamp OR the branchid.

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Mikael
2016-05-15 22:14 GMT+07:00 Simon Slavin : > > On 15 May 2016, at 4:02pm, Mikael wrote: > > > Simon, yes using only INSERT and DELETE in total would be fine with me > (and > > perhaps BEGIN and COMMIT if it's OK). > > > > What are you thinking about? > > > > Did you see a purely SQL-based

[sqlite] 64bit DLL vs 32bit

2016-05-15 Thread Bart Smissaert
So, is there any way that a 32 bit VB6 ActiveX dll or a32 bit VB6 ActiveX exe could access a 64 bit SQLite dll? All this only comes into play for me when using 64 bit VBA in Excel. I have no problem to access the 64 bit SQLite dll from 64 bit VBA. RBS On Sun, May 15, 2016 at 7:12 PM, Richard

[sqlite] Sqlite incompatibility with Postgres

2016-05-15 Thread Darren Duncan
On 2016-05-15 9:56 PM, J Decker wrote: > On Sun, May 15, 2016 at 9:29 PM, Darren Duncan > wrote: >> On 2016-05-15 12:35 AM, Simon Slavin wrote: >>> >>> All true. But it brings up a question. Suppose the following: >>> >>> first second >>> - -- >>> MarkSpark >>> Emily Spark

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Mikael
2016-05-15 21:56 GMT+07:00 Simon Slavin : > > On 15 May 2016, at 3:52pm, Mikael wrote: > > > Would there be any facility whereby after each transaction I do on a > > database or table, I could somehow make a snapshot so that at any future > > point in time, I could easily do a SELECT to a given

[sqlite] Clarify in docs that PRAGMA integrity_check also checks that index content matches table content?

2016-05-15 Thread Mikael
Hi, The documentation for "PRAGMA quick_check" ( http://www.sqlite.org/pragma.html#pragma_quick_check) points out that "PRAGMA integrity_check" will match index content with table content. http://www.sqlite.org/pragma.html#pragma_integrity_check , which is the actual documentation for that

[sqlite] Sqlite incompatibility with Postgres

2016-05-15 Thread J Decker
On Sun, May 15, 2016 at 9:29 PM, Darren Duncan wrote: > On 2016-05-15 12:35 AM, Simon Slavin wrote: >> >> On 15 May 2016, at 6:04am, Darren Duncan wrote: >> >>> You seem to be forgetting the fact that LIMIT/OFFSET is not its own >>> clause, rather it is an extension to the ORDER BY clause and

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Mikael
Hi! Would there be any facility whereby after each transaction I do on a database or table, I could somehow make a snapshot so that at any future point in time, I could easily do a SELECT to a given version/snaphot? Any solution based purely on SQL would be extremely expensive I guess (e.g.

[sqlite] Sqlite incompatibility with Postgres

2016-05-15 Thread Darren Duncan
On 2016-05-15 12:35 AM, Simon Slavin wrote: > On 15 May 2016, at 6:04am, Darren Duncan wrote: > >> You seem to be forgetting the fact that LIMIT/OFFSET is not its own clause, >> rather it is an extension to the ORDER BY clause and only has meaning within >> the context of the ORDER BY it is

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread dandl
> > 1. Why SQLite is popular. > > The answers to those question mentioned in the podcast may be good ones but I > think the main reason is that it's free. Completely, unmistakably, free. Necessary but not sufficient. It's free, and the licence is as non-restrictive as it is possible to be. >

[sqlite] using cerod/sqlite with JDBC

2016-05-15 Thread Tal Tabakman
Hi is there a way to open an sqlite DB , compressed with CEROD, using java?s sqlite JDBC connection ? thanks Tal

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Dominique Devienne
On Sunday, May 15, 2016, Mikael wrote: > > Would there be any facility whereby after each transaction I do on a > database or table, I could somehow make a snapshot so that at any future > point in time, I could easily do a SELECT to a given version/snaphot? WAL basically does this already. But

[sqlite] Illegal hexadecimal number literal

2016-05-15 Thread gwenn
Hello, SQLite version 3.8.10.2 2015-05-20 18:17:19 sqlite> select 0x1g; 1 sqlite> select 1g; Error: unrecognized token: "1g" The illegal number 0x1g is not rejected. Maybe, in tokenice.c, This block should not return directly but check that z[i] is not an IdChar if( z[0]=='0' &&

[sqlite] Computed column or create index on a view ?

2016-05-15 Thread Jean-Luc Hainaut
- No index on a view in SQLite (so far). - A computed column can be maintained through appropriate triggers (here, "on insert" and "on update"). Efficient if you read data more than you modify them. - Perhaps trying this: create table readings(...); create index trg_cx on

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Tony Papadimitriou
>> > 1. Why SQLite is popular. >> >> The answers to those question mentioned in the podcast may be good ones >> but I >> think the main reason is that it's free. Completely, unmistakably, free. > >Necessary but not sufficient. >It's free, and the license is as non-restrictive as it is possible

[sqlite] Clarify in docs that PRAGMA integrity_check also checks that index content matches table content?

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 3:59pm, Mikael wrote: > What about writing it there, for everyone to understand how robust "PRAGMA > integrity_check" really is? > > > (Without that clarification, it looks like it'll just check database format > correctness and the relative consistency of UNIQUE columns.)

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 4:23pm, Mikael wrote: > Do you see any way that I could implement *one* layer of branches atop of > this? I suspect that branching would be harder to implement. Storing a branch code in another column of the table isn't going to help much. You'd need to create some kind

[sqlite] Computed column or create index on a view ?

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 4:08pm, Jean-Luc Hainaut wrote: > - A computed column can be maintained through appropriate triggers (here, "on > insert" and "on update"). Efficient if you read data more than you modify > them. Hmm. Yes, you're right. Your way of simulating it is better than my way of

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 4:02pm, Mikael wrote: > Simon, yes using only INSERT and DELETE in total would be fine with me (and > perhaps BEGIN and COMMIT if it's OK). > > What are you thinking about? > > Did you see a purely SQL-based solution that I don't? BEGIN and COMMIT make no changes to stored

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 3:52pm, Mikael wrote: > Would there be any facility whereby after each transaction I do on a > database or table, I could somehow make a snapshot so that at any future > point in time, I could easily do a SELECT to a given version/snaphot? Do you need a solution which works

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 3:17pm, Scott Robison wrote: > True. Last December I received a notice that a patch I submitted to a Trac > plugin had finally been accepted. Over seven years after I submitted it. I once submitted a bug report to Apple. Four months later it was acknowledged as a duplicate

[sqlite] Computed column or create index on a view ?

2016-05-15 Thread Simon Slavin
I know that SQLite does not currently implement these things but I'm curious if anyone else wants them and how hard they would be to implement. I have what you might consider to be a computed column. You might imagine CREATE TABLE readings (timestamp TEXT PRIMARY KEY, a REAL, b

[sqlite] 64bit DLL vs 32bit

2016-05-15 Thread dandl
> > But I think if you compile code for the x64 processor chip and call it > > from x86 or vice versa then either it doesn't work or you pay a high > > price for thunking from one to the other. I think that's unavoidable > > regardless of OS. > > Right: doesn't work. There's no performance

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 2:14pm, mikeegg1 wrote: > As a side thought of what I?ve listened to so far? Is there a > page/reference/discussion about how the consortium was/is set up? > I am integrating SQLite into my Mac OS X application and like SQLite. I am > curious how the consortium is

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Stephan Beal
On Sun, May 15, 2016 at 2:29 PM, Tim Streater wrote: > What's all this about licences. AIUI, SQLite is explicitly in the public > domain. Meaning the question of licence doesn't arise. > it does, actually, because PD is not recognized in all jurisdictions. -- - stephan beal

[sqlite] Sqlite incompatibility with Postgres

2016-05-15 Thread dandl
> I suggest the reason LIMIT hasn't been standardized is that it's contrary to > the fundamental idea that rows in a table have no meaningful order. SQL > doesn't honor relational theory with complete > fidelity, but at least that horse is still in the barn. Point 1: I think you'll find plenty

[sqlite] 64bit DLL vs 32bit

2016-05-15 Thread dandl
> > Actually, it's everyone using a language other than C/C++, plus a > > proportion of those too. I use C#, but if you want to call Sqlite from > > Java, Python, etc or even some generic C/C++ app that supports > > plug-ins, then at some point there is a DLL > > How does that follow? Any

[sqlite] 64bit DLL vs 32bit

2016-05-15 Thread Richard Damon
On 5/15/16 1:00 AM, dandl wrote: >>> But I think if you compile code for the x64 processor chip and call it >>> from x86 or vice versa then either it doesn't work or you pay a high >>> price for thunking from one to the other. I think that's unavoidable >>> regardless of OS. >> Right: doesn't

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Tim Streater
On 15 May 2016 at 11:53, dandl wrote: >>> 1. Why SQLite is popular. >> >> The answers to those question mentioned in the podcast may be good ones > but I >> think the main reason is that it's free. Completely, unmistakably, free. > > Necessary but not sufficient. > > It's free, and the licence

[sqlite] Any way to do inexpensive SQLite database/table versioning? (I.e. cheap snapshotting & jumping between)

2016-05-15 Thread mikeegg1
I was once told of an idea (decades ago) of versioning data within a table where one column has a real/float value that is the version number. The data in the table can be committed as necessary. If the data needs to be rolled back the data can be rolled back/deleted to the table based on the

[sqlite] Time & between, midnight wrap around

2016-05-15 Thread Scott Robison
Off the top of my head: Select case when t1 < t2 then t3 between t1 and t2 when t1 > t2 then t3 >= t1 or t3 <= t2 end You might need to tweak it to handle the case when t1 = t2 if needed. Could mean one minute or could mean 24 hours depending on your pov. Hello, BETWEEN doesn't give the result I

[sqlite] Sqlite incompatibility with Postgres

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 6:04am, Darren Duncan wrote: > You seem to be forgetting the fact that LIMIT/OFFSET is not its own clause, > rather it is an extension to the ORDER BY clause and only has meaning within > the context of the ORDER BY it is part of. All true. But it brings up a question.

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Simon Slavin
On 15 May 2016, at 6:35am, Roman Fleysher wrote: > 1. Why SQLite is popular. The answers to those question mentioned in the podcast may be good ones but I think the main reason is that it's free. Completely, unmistakably, free. You could make many changes to SQLite and people would

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Scott Robison
On May 15, 2016 8:06 AM, "Tony Papadimitriou" wrote: >>> > (Many open source projects have bugs waiting for months or years for someone to be bothered to fix, often driving people away!) > > To sum it up, a big thanks to Richard and his team! True. Last December I received a notice that a patch

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread mikeegg1
I?m listening to the podcast now. Great episode and I?ve subscribed to their podcast series. As a side thought of what I?ve listened to so far? Is there a page/reference/discussion about how the consortium was/is set up? I am integrating SQLite into my Mac OS X application and like SQLite. I am

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Scott Robison
On May 15, 2016 6:30 AM, "Tim Streater" wrote: > > What's all this about licences. AIUI, SQLite is explicitly in the public domain. Meaning the question of licence doesn't arise. The question of license arises when comparing two pieces of software. While PD isn't a license per se, it is

[sqlite] Podcast with Dr Hipp: SQLite history, success and funding

2016-05-15 Thread Roman Fleysher
Dear Richard, Dear SQLiters, Thank you, Simon, for sending the link. I would like to offer several comments on the podcast. 1. Why SQLite is popular. Instead of describing how I selected SQLite to solve our DB needs, I will recount story of Sony, its introduction of transistor radio that I