Re: [sqlite] [EXTERNAL] Re: COALESCE() does not short-circuit sometimes

2020-03-12 Thread Doug
(a, abs(0), abs(1), abs(2)) FROM t1; Just curious... Doug > -Original Message- > From: sqlite-users > On Behalf Of Richard Hipp > Sent: Thursday, March 12, 2020 7:41 AM > To: SQLite mailing list > Subject: Re: [sqlite] [EXTERNAL] Re: COALESCE() does not short- > circui

Re: [sqlite] [EXTERNAL] Re: COALESCE() does not short-circuit sometimes

2020-03-12 Thread Doug
Richard, what does the explain look like with your code change, please. Doug > -Original Message- > From: sqlite-users > On Behalf Of Richard Hipp > Sent: Thursday, March 12, 2020 3:09 AM > To: SQLite mailing list > Subject: Re: [sqlite] [EXTERNAL] Re: COALESC

Re: [sqlite] Check constrain execution timing change? (Now a bug)

2020-02-04 Thread Doug
> On Tue, Feb 4, 2020 at 5:38 PM Doug wrote: > > > You're twisting my point here. I obviously want the reverse, > > > I want the database types to "drive" the binding done. 1-to-1. > > > Because even if binding a different type would work, via > SQLi

Re: [sqlite] Check constrain execution timing change? (Now a bug)

2020-02-04 Thread Doug
match the column type. So, if you are generating text SQL statements: Is the code inadvertently putting quotes (') around in integer value or is the user entering a string and your code is taking that input and slapping it into a SQL INSERT statement? Please expl

Re: [sqlite] FW: Questions about your "Performance Matters" talk re SQLite

2020-01-04 Thread Doug
> -Original Message- > From: sqlite-users > On Behalf Of J Decker > Sent: Saturday, January 04, 2020 4:11 AM > > Could wish there was a way to > pause execution without giving up execution context... What about? for (i=1000; i--; i>0); ___

Re: [sqlite] FW: Questions about your "Performance Matters" talk re SQLite

2020-01-04 Thread Doug
Thanks, Jens. I got it. The benchmark sounds like it isn't a real benchmark, but a made-up scenario to exercise the Coz code. I've let go now. Doug > -Original Message- > From: sqlite-users > On Behalf Of Jens Alfke > Sent: Friday, January 03, 2020 10:58 PM > To: SQLi

[sqlite] FW: Questions about your "Performance Matters" talk re SQLite

2020-01-02 Thread Doug
are run on lots of different machines (all over the world?), it would provide an excellent view of what changes in SQLite made a difference in performance. Doug From: Curtsinger, Charlie Sent: Thursday, January 02, 2020 10:55 AM To: dougf@comcast.net Cc: Emery D Berger Subject: Re

Re: [sqlite] Causal profiling

2019-12-30 Thread Doug
; presumably, we already have test cases that test the same code using different compiler options. What about that? Best, Doug > -Original Message- > From: sqlite-users > On Behalf Of Jens Alfke > Sent: Friday, December 27, 2019 2:22 PM > To: SQLite mailing list > Su

Re: [sqlite] Causal profiling

2019-12-26 Thread Doug
> -Original Message- > From: sqlite-users > On Behalf Of Jens Alfke > Sent: Thursday, December 26, 2019 3:11 PM > To: SQLite mailing list > Subject: Re: [sqlite] Causal profiling > > > > > On Dec 25, 2019, at 2:53 PM, Doug wrote: > > > > I

Re: [sqlite] Causal profiling

2019-12-25 Thread Doug
at the talk again re performance measurements), what did you use to measure the results? Best, Doug > -Original Message- > From: sqlite-users > On Behalf Of Richard Hipp > Sent: Wednesday, December 25, 2019 3:18 PM > To: SQLite mailing list > Subject: Re: [sqlite

Re: [sqlite] Result set column names

2019-12-10 Thread Doug
For column "xxx" what will the full column name be? "foo.xxx"? Doug > -Original Message- > From: sqlite-users > On Behalf Of Simon Slavin > Sent: Tuesday, December 10, 2019 10:37 AM > To: SQLite mailing list > Subject: Re: [sqlite] Result set colum

Re: [sqlite] Result set column names

2019-12-10 Thread Doug
xx) VALUES(25) SELECT xxx FROM foo ---|- xxx 25 Doug > -Original Message- > From: sqlite-users > On Behalf Of Adrian Ho > Sent: Tuesday, December 10, 2019 8:04 AM > To: sqlite-users@mailinglists.sqlite.org > Subject: Re: [sqlite] Result set column names > &g

Re: [sqlite] Question about: Adding a record to a table with select failure

2019-11-19 Thread Doug
d. However, the domain of "a" is 'p001', 'p002',... It is not a date which would be returned by Max(idate). I know you are trying to use side effects, but I don't understand ??? Doug > -Original Message- > From: sqlite-users > On Behalf Of Jose Isaias Cabrera > Sent: Mo

Re: [sqlite] Question about: Adding a record to a table with select failure

2019-11-18 Thread Doug
; Doesn't the where clause that cannot be satisfied in both cases guarantee that no rows will be selected, when there are no records in the database? Doug > -Original Message- > From: sqlite-users > On Behalf Of Jose Isaias Cabrera > Sent: Monday, November 18, 2019 12:11 PM >

Re: [sqlite] Question about: Adding a record to a table with select failure

2019-11-18 Thread Doug
t; >IfNull(c, 2),​ > >'y',​ > >IfNull(e, 4),​ > >'2019-20-12'​ > > FROM t​ > > WHERE a = 'p006';​ I think that you will never insert the first record with a query like this, since the select returns 0 records of there are none

Re: [sqlite] Question about: Adding a record to a table with select failure

2019-11-15 Thread Doug
WRT Jose's original context, and just for my enlightment, what happens with the following: insert into t (a, b, c, d, e, idate) SELECT a, b, c, 'y', e, '2019-02-12' FROM t WHERE a = 'p999'; where p999 does not define a record? Is a new record inserted with values of a,b,c, and e null? >

Re: [sqlite] Things you shouldn't assume when you store names

2019-11-09 Thread Doug
exist as that name. The "names" article is totally wrong when it says that each assumption is wrong. Each of those assumptions is correct, and I can find at least one system which makes each one correct. Within each system, the assumption works, and is valid. My two cen

Re: [sqlite] Deterministic random sampling via SELECT

2019-11-07 Thread Doug Currie
On Thu, Nov 7, 2019 at 4:23 PM Richard Damon wrote: > > One thought would be to generate a ‘hash’ from part of the record, maybe > the record ID, and select records based on that value. The simplest would > be something like id%100 == 0 would get you 1% of the records. That > admittedly isn’t

Re: [sqlite] https://www.sqlite.org/draft/gencol.html Typo

2019-10-29 Thread Doug
te mailing list > Subject: Re: [sqlite] https://www.sqlite.org/draft/gencol.html > Typo > > > On Tuesday, 29 October, 2019 12:25, Doug > wondered: > > >The draft says "Nor may a generated column depend on the ROWID." > > >If my table uses ROWID by default:

Re: [sqlite] https://www.sqlite.org/draft/gencol.html Typo

2019-10-29 Thread Doug
The draft says "Nor may a generated column depend on the ROWID." If my table uses ROWID by default: CREATE TABLE foo (id INTEGER PRIMARY KEY, a INTEGER, b AS (id+a)); where id is ROWID by default, is the generated column disallowed because it has an implied dependency on RO

Re: [sqlite] Can SQLite do this in a single query?

2019-10-22 Thread Doug
Please explain one phrase in the select: total(1) over (partition by city_txt, mode_txt) Is "total" a function and does "1" refer to city_txt? I can't wrap my head around what's going on with this phrase. Doug > -Original Message- > From: sqlite-users &g

Re: [sqlite] Last record

2019-10-15 Thread Doug
How about something like this that costs more to run: Given a table T with columns A, B, C,.. BEGIN TRANSACTION SELECT Count(*) AS Count [filter spec]; SELECT A,B,C,... [filter spec]; ROLLBACK or COMMIT Doug > -Original Message- > From: sqlite-users > On Behalf Of Simon Slav

Re: [sqlite] Date time input

2019-10-08 Thread Doug
I like SQLoaded! Doug > -Original Message- > From: sqlite-users > On Behalf Of Jose Isaias Cabrera > Sent: Tuesday, October 08, 2019 12:15 PM > To: sqlite-users@mailinglists.sqlite.org > Subject: Re: [sqlite] Date time input > > > James K. Lowden, on Tuesda

Re: [sqlite] Fastest way to SELECT on a set of keys?

2019-09-13 Thread Doug
I blows me away that you are able to produce such things as this at the drop of a hat! Thanks for your insights and ingenuity and completeness! Doug > -Original Message- > From: sqlite-users > On Behalf Of Keith Medcalf > Sent: Friday, September 13, 2019 1:30 PM > To:

Re: [sqlite] what's wrong with this trigger

2019-09-09 Thread Doug
What works, please? I saw no answer. Doug > -Original Message- > From: sqlite-users > On Behalf Of Rael Bauer > Sent: Monday, September 09, 2019 7:01 PM > To: sqlite-users@mailinglists.sqlite.org > Subject: Re: [sqlite] what's wrong with this trigger >

Re: [sqlite] [SPAM?] Re: [EXTERNAL] Re: Should SQLite distinguish between +0.0 and -0.0 on output?

2019-06-14 Thread Doug Currie
On Fri, Jun 14, 2019 at 7:16 AM R Smith wrote: > > What I was objecting to, is claiming (in service of suggesting the > use-case for -0.0), [...] > > I'll be happy to eat my words if someone can produce a mathematical > paper that argued for the inclusion of -0.0 in IEEE754 to serve a >

Re: [sqlite] [SPAM?] Re: [EXTERNAL] Re: Should SQLite distinguish between +0.0 and -0.0 on output?

2019-06-13 Thread Doug
an application might implement the functionality. --Doug ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] [SPAM?] Re: [EXTERNAL] Re: Should SQLite distinguish between +0.0 and -0.0 on output?

2019-06-13 Thread Doug Currie
> > I do not know if this is the result case in any of the programming > languages, but in Mathematical terms that is just not true. > The related IEEE 754 rules are described here: https://en.wikipedia.org/wiki/Signed_zero e ___ sqlite-users mailing

Re: [sqlite] [SPAM?] Re: [EXTERNAL] Re: Should SQLite distinguish between +0.0 and -0.0 on output?

2019-06-13 Thread Doug Currie
> > > Except by the rules of IEEE (as I understand them) > > -0.0 < 0.0 is FALSE, so -0.0 is NOT "definitely left of true zero" > Except that 0.0 is also an approximation to zero, not "true zero." Consider that 1/-0.0 is -inf whereas 1/0.0 is +int e

Re: [sqlite] sqlite-users Digest, Vol 138, Issue 4

2019-06-04 Thread Doug
A|57616C747A|5|5|Waltz|1|American Smooth Notice that nullif() failed to find the field and the literal equal. That is consistent with the failure. Doug > -Original Message- > From: sqlite-users > On Behalf Of sqlite-users-requ...@mailinglists.sqlite.org > Sen

Re: [sqlite] sqlite-users Digest, Vol 138, Issue 4

2019-06-04 Thread Doug
l in the database for text fields that is/is not in play here? Doug > -Original Message- > From: sqlite-users > On Behalf Of sqlite-users-requ...@mailinglists.sqlite.org > Sent: Tuesday, June 04, 2019 5:00 AM > To: sqlite-users@mailinglists.sqlite.org > Subject: sqlite-users Digest, V

[sqlite] select * where abc like "xxx" works, ...where abc='xxx' fails

2019-06-03 Thread Doug
he table and the queries to a single column for this message. The actual table has 22 columns. Why does the "=" query fail and the "like" query work? Regards, Doug ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] JDBC driver experience

2018-04-22 Thread Doug White
be causing the problem. A working android studio code example would be wonderful to analyze. Doug White dglsn...@gmail.com On Apr 22, 2018 12:42 PM, "Seiji Amalai" <seijiama...@gmail.com> wrote: no On Wed, Apr 18, 2018 at 8:34 PM, Richard Hipp <d...@sqlite.org> wrote:

Re: [sqlite] How many AUTOINCREMENT tables are in your schema?

2018-03-16 Thread Doug Currie
0 ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Question about Practicality of Embedding SQLite on Cortex-M4 Processor

2018-03-02 Thread Doug Currie
On Fri, Mar 2, 2018 at 2:46 PM, Obrien, John J wrote: > [...] > > To summarize, my question is regarding what direction I should ask the > hardware vendor to take. Does it make sense for them to spend time > optimizing the SAM4S for SQLite or should we consider another

Re: [sqlite] difference between 'ID IS NULL' and 'ID = NULL'

2018-01-05 Thread Doug Currie
Cezary is correct, NULL is not equal to NULL, though NULL is NULL. sqlite> select NULL IS NULL; 1 sqlite> select NULL = NULL; sqlite> e ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org

Re: [sqlite] Ordering a GROUP BY, or other concatenating tricks?

2017-10-04 Thread Doug Nebeker
Is it just a matter of using sqlite3_create_function to register a function that guarantees it will concatenate in the order rows are received? Would that guarantee that your example works, or is order no longer guaranteed once they leave the inner select? SELECT group_concat(LineText, '\n')

[sqlite] Ordering a GROUP BY, or other concatenating tricks?

2017-10-03 Thread Doug Nebeker
Imagine a table that holds individual lines of text documents: CREATE TABLE DocLines ( DocID INTEGER, LineIndex INTEGER, LineText TEXT ); INSERT INTO DocLines (DocID, LineIndex, LineText) VALUES (1, 1, 'Mary had a little lamb'); INSERT INTO DocLines (DocID, LineIndex,

Re: [sqlite] Simple web query tool

2017-02-01 Thread Doug Currie
On Wed, Feb 1, 2017 at 11:10 AM, Jay Kreibich wrote: > I'm looking for an *extremely* simple web tool that will allow me to > configure a dozen or so stored queries, which people can then select and > run on an internal server. While I wouldn't call it extremely simple, the

Re: [sqlite] Simplify multiple use of value in a trigger

2017-01-07 Thread Doug Currie
On Sat, Jan 7, 2017 at 9:27 AM, Gan Uesli Starling wrote: > So I'm trying to accumulate data for state/prov inside of USA, Canada and > Mexico, and country for the rest of the world. > > Since country and state from the same update are factors in incrementing > each of four

Re: [sqlite] Datatype for prices (1,500)

2016-11-30 Thread Doug Currie
On Wed, Nov 30, 2016 at 5:25 PM, Nico Williams wrote: > On Wed, Nov 30, 2016 at 02:22:42PM -0600, John McKown wrote: > > > > [...] every RDMS "should" implement Decimal Floating Point. > > You could argue that every programming language needs that. What makes > SQL more

Re: [sqlite] SQLite - how to get number of active connection?

2016-09-10 Thread Doug Nebeker
This isn't exactly the same, but you can find out what other applications have a file open (SQLite database file in this case) using the following Windows APIs: RmRegisterResources RmGetList That's what I use to help diagnose locking issues. Doug -Original Message- From: sqlite-users

Re: [sqlite] Failed to install Microsoft Visual C++ Runtime

2016-08-02 Thread Doug Nebeker
is also needed. Look at KB2919355. It's a mess :( Once you can get it and all its dependencies installed, everything works great. But you often need to do more than just install the vcredist as had always been the case in the past. We even did a technical support case with MS. Doug

[sqlite] Database corruption question

2016-07-20 Thread Doug Nebeker
bug or environmental than being in SQLite, so I'm looking for anything I can do to decrease these occurrences. Thanks for any input. Doug ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listi

Re: [sqlite] Bug: SQLite's include guards are reserved identifiers

2016-07-09 Thread Doug Currie
On Sat, Jul 9, 2016 at 12:05 PM, Keith Medcalf wrote: > > [...] Most API headers do the same thing. Even the standard library does > it, in most compilers. [...] Sure, that's why they're reserved! So user code and the C compiler's library implementation don't clash. The

[sqlite] Article about pointer abuse in SQLite

2016-03-23 Thread Doug Nebeker
).aspx This fits with my experience as well. Doug -Original Message- From: sqlite-users-bounces at mailinglists.sqlite.org [mailto:sqlite-users-boun...@mailinglists.sqlite.org] On Behalf Of Keith Medcalf Sent: Tuesday, March 22, 2016 8:41 PM To: SQLite mailing list Subject: Re: [

[sqlite] File Locking Status

2016-03-08 Thread Doug Currie
> Is it possible to tell if SQLite has a database file locked? Not through > OS tools, but from System.Data.SQlite? If you can execute BEGIN EXCLUSIVE TRANSACTION and get back SQLITE_OK then there were no locks on the database. Of course you will then need to ROLLBACK. Note that this

[sqlite] Are BLOB stored inline with the rest of the record fields?

2016-03-02 Thread Doug Currie
On Wed, Mar 2, 2016 at 4:42 PM, R Smith wrote: > > > Personally, unless your space is constrained, I would simply save the > numbers as strings, perhaps Hex or BCD with leading chars and convert as > needed. This would sort correctly without tricks and not do much worse for > space. (Base64 would

[sqlite] Rare database corruption - does this help?

2015-09-10 Thread Doug Nebeker
I'm hoping this might be of help to contribute to SQLite's robustness. We've got thousands of SQLite installations and they almost always work flawlessly. Every once in a while we get a corruption error and I finally have a log that catches it. SQLite has been in use in the project since

[sqlite] insert in sqlite (returning value for inserted row)

2015-04-01 Thread Doug Currie
Suraj, Don't use the same database connection in multiple threads. Each thread should use its own connection. Then last insert rowid is predictable. e On Wed, Apr 1, 2015 at 1:10 PM, Kumar Suraj wrote: > Hi Richard.. this wont work for me due to following reason. > > If a separate thread

[sqlite] PRAGMA Synchronous safety

2015-03-02 Thread Doug Nebeker
ore continuing Yes. Once we get the report, the user has to delete the file and start fresh with an empty database. > Depends on whether you are using WAL mode or not. I am not using WAL. Doug -Original Message- From: sqlite-users-bounces at mailinglists.sqlite.org [ma

[sqlite] PRAGMA Synchronous safety

2015-03-02 Thread Doug Nebeker
at a time. The database is on a local NTFS drive. Two questions: 1. Is setting synchronous to FULL necessary to prevent these corruption problems? 2. NORMAL is much slower than NONE. Is FULL much slower than NORMAL? Thanks Doug

Re: [sqlite] unreached code in sqlite3.c?

2015-02-12 Thread Doug Currie
On Thu, Feb 12, 2015 at 1:35 PM, R.Smith wrote: > > Now one could argue the warning should not be issued for it, or some > warnings are fine as information. Personally I prefer zero unneeded > warnings/clutter but that's just my pedantism. > My pedantism is to prefer the

Re: [sqlite] unreached code in sqlite3.c?

2015-02-12 Thread Doug Currie
Well, if TERM_VNULL is 0, then the code is truly unreachable, so I wouldn't call it a compiler bug. e On Thu, Feb 12, 2015 at 9:26 AM, Richard Hipp wrote: > Dan is right. I think I'd calling this a clang bug. > On Feb 12, 2015 9:06 AM, "Dan Kennedy"

Re: [sqlite] ordinary CTE containing sum()

2015-02-09 Thread Doug Currie
Thank you, Richard. It works for me now. e On Mon, Feb 9, 2015 at 1:30 PM, Richard Hipp <d...@sqlite.org> wrote: > On 2/7/15, Doug Currie <doug.cur...@gmail.com> wrote: > > In response to this SO question: > > > > > http://stackoverflow.com/questions

Re: [sqlite] ordinary CTE containing sum()

2015-02-09 Thread Doug Currie
For those interested in the initial "misuse of aggregate" issue of this thread, there is now a ticket: http://www.sqlite.org/src/tktview?name=2f7170d73b e On Mon, Feb 9, 2015 at 9:19 AM, Keith Medcalf wrote: > > Not exactly since aggregates are implemented as functions.

Re: [sqlite] ordinary CTE containing sum()

2015-02-08 Thread Doug Currie
> > > In response to this SO question: > > > > > http://stackoverflow.com/questions/28377210/how-to-retrieve-rank-based-on-total-mark-in-sqlite-table > > > > I tried to formulate a query without temp tables using an ordinary > > CTE, but received an error "misuse of aggregate: sum()". > tonypdmtr

[sqlite] ordinary CTE containing sum()

2015-02-07 Thread Doug Currie
In response to this SO question: http://stackoverflow.com/questions/28377210/how-to-retrieve-rank-based-on-total-mark-in-sqlite-table I tried to formulate a query without temp tables using an ordinary CTE, but received an error "misuse of aggregate: sum()". This works: sqlite> with tt (S_id,

Re: [sqlite] Best Practice: Storing Dates

2015-01-14 Thread Doug Nebeker
Whatever format you choose to store it in, I highly recommend storing the UTC time. It might be a little more work, but: 1. your program can display the correct local time, even if the database/app/user is in/changes to another timezone 2. you won't have to deal with seeing two 1:30am on the

Re: [sqlite] decoding a bitmask

2014-10-13 Thread Doug Currie
> > The query is on a visits table from a google chrome history database. The > query seems to work OK if a single bit is set, but fails (a blank string is > returned) when multiple bits are set. Any ideas why? > It's because none of the WHEN 0x... cases, except 0xC0..., have multiple bits set.

Re: [sqlite] Hexadecimal integer literals

2014-07-23 Thread Doug Currie
> > > Here's an analogy: a sequence of decimal digits is unsigned; it only > > becomes negative when you put a "-" in front of it. > > > > Why shouldn't hex work the same way? (to eliminate the discombobulating > > segment) > > > > Because then you would not be able to write (in hex) a 64-bit

Re: [sqlite] Hexadecimal integer literals

2014-07-23 Thread Doug Currie
> Why are hex literals interpreted as signed at all? You could simply > > consider all hex literals as unsigned values. If you need a negative > value, > > prefix it with the - operator, e.g., -0x77. > > > > With this approach (a) there is no discombobulating segment, (b) all 64 > bit > >

Re: [sqlite] Hexadecimal integer literals

2014-07-23 Thread Doug Currie
> There is this range of negative > values smack in the middle of an otherwise uniformly increasing sequence of > positive numbers. That negative range seems discombobulating. Why are hex literals interpreted as signed at all? You could simply consider all hex literals as unsigned values. If

Re: [sqlite] Primary Key without DataAnnotation for Windows Runtime

2014-04-01 Thread Doug McDonald
__ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > -- Doug McDonald BSc(Hons) | MCTS | MBCS ___ sqlite-users mailing list sqlite-users@sqlite.o

[sqlite] Documentation error: sqlite3_mutex_try

2014-02-15 Thread Doug Nebeker
The documentation says that sqlite3_mutex_try will always return SQLITE_BUSY for "some systems (for example, Windows 95)". That's not quite accurate from what I see in the latest implementation of winMutexTry. It will ALWAYS return SQLITE_BUSY for any Windows usage, making the existence of

Re: [sqlite] Concrete example of corruption

2013-12-05 Thread Doug Currie
On Dec 5, 2013, at 8:55 PM, Warren Young wrote: > On 12/5/2013 17:00, Scott Robison wrote: >> Might there be a way to implement a custom VFS for Mac to deal with this? > > Wouldn't it be a lot simpler to just put the DB file into a Mac package (i.e. > directory) so the

Re: [sqlite] SQLite version 3.8.2 running 2.5x faster for some queries.

2013-11-24 Thread Doug Currie
On Nov 24, 2013, at 6:47 AM, Alek Paunov wrote: > > BTW, I see the term "deterministic" in the SQL99 BNFs: > … > but different in PostgreSQL ("immutable", "stable", etc): There is value in compatibility, but those adjectives are awful. In computer science we have

Re: [sqlite] Mystery why SQLite will not work until System.Data.SQLite has been installed

2013-10-23 Thread Doug Currie
Paul Bainter wrote: > > > > Not sure what happened to this post previously, so I guess I'll try it > > again with some additional information > GMail considered these messages spam for some reason. Check your spam folder. e ___ sqlite-users mailing

Re: [sqlite] Hints for the query planner

2013-09-11 Thread Doug Currie
On Sep 10, 2013, at 6:23 PM, Scott Robison wrote: > I think I prefer something along the lines of "unlikely" or "likely". The > problem with a term like "selective" (at least in my brain) is that it > doesn't imply (for the single argument version) in what way it is

Re: [sqlite] To BEGIN or not to BEGIN. That is the question...

2013-08-30 Thread Doug Nebeker
Igor is naturally correct. One additional thing to keep in mind - the commit phase of a transaction is where a lot of work gets done (meaning slow disk access). So if you have a lot of INSERTs or DELETEs to do, doing many within a transaction will give you better performance. Doug

Re: [sqlite] CREATE INDEX and column order

2013-08-28 Thread Doug Nebeker
...@sqlite.org] On Behalf Of Simon Slavin Sent: Tuesday, August 27, 2013 7:29 AM To: General Discussion of SQLite Database Subject: Re: [sqlite] CREATE INDEX and column order On 27 Aug 2013, at 1:07pm, Doug Nebeker <ad...@poweradmin.com> wrote: > I was reading about the new quer

[sqlite] CREATE INDEX and column order

2013-08-27 Thread Doug Nebeker
using that as my right-most column, but it seems it would be a great candidate to be switched. Thanks Doug ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] [Bug] sqlite3_finalize() *DOES NOT* return most recent evaluation error code

2013-08-21 Thread Doug Currie
> I'm unable to reproduce the problem using C. Maybe it is in lsqlite3. Yes, lsqlite3 still uses the old sqlite3_prepare() API to maintain compatibility with some legacy systems. It is long past time that it should have changed to use sqlite3_prepare_v2(). Running Richard's example with

Re: [sqlite] Beginning database question

2013-04-17 Thread Doug Nebeker
ies? That's my best shot. Doug -Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Carl Gross Sent: Tuesday, April 16, 2013 3:28 AM To: sqlite-users@sqlite.org Subject: [sqlite] Beginning database question Hi All, I'm an amateur

[sqlite] set journal off working witth SQLiteConfig?

2013-03-14 Thread Doug Crites
n settings for large transactions like this, please share! Thanks, Doug Doug Crites Sr Software Engineer doug.cri...@asg.com<mailto:doug.cri...@asg.com> The Commons 708 Goodlette Road N Naples, FL 34102 Tel: 239.435.2293 Fax: 239.213.3501 Toll-Free: 800.932.5536 USA Only www.asg.com<http:

Re: [sqlite] SQLite strong-typing [WAS: inner vs. outer join inconsistency]

2013-03-07 Thread Doug Currie
On Mar 7, 2013, at 11:07 AM, Ryan Johnson wrote: > > That does leave the question of what to do with cast ('1.0' as integer), > though. Without the prefix-based matching that would now return NULL rather > than 1, even though cast(1.0 as integer) would still

Re: [sqlite] VC++ and SQLite

2012-11-12 Thread Doug Nebeker
You might be surprised at the speed increase you see in compile time if you've got large projects. The time isn't lost to CPU as much, but disk I/O time adds up when hitting many hundreds of small (header) files (even with an SSD). Doug -Original Message- From: sqlite-users-boun

Re: [sqlite] Mac development question

2012-10-23 Thread Doug Currie
On Oct 23, 2012, at 4:58 PM, Igor Korot wrote: > 1. I know on Mac I need to build an application bundle. Where do I > store the .db file relative to the bundle? > Inside it? Home directory? Somewhere on the hard drive? What is the > usual place for it? If the database is

Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Doug Currie
On Aug 6, 2012, at 4:51 PM, Simon Slavin <slav...@bigfraud.org> wrote: > On 6 Aug 2012, at 7:48pm, Doug Currie <doug.cur...@gmail.com> wrote: > >> ~ e$ /usr/local/bin/sqlite3 :memory: 'SELECT sqlite_source_id()' >> 2012-05-14 01:41:23 8654aa9540fe9fd210899d8

Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Doug Currie
On Aug 6, 2012, at 8:26 AM, Simon Slavin wrote: > So either Apple has made a change between versions, or we have different > paths. I use fully qualified pathnames here: ~ e$ /usr/bin/sqlite3 :memory: 'SELECT sqlite_source_id()' 2012-04-03 19:43:07

Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Doug Currie
On Aug 3, 2012, at 3:32 PM, Tobias Giesen wrote: > Apparently Apple prevents starting other versions of it and redirects > everything to > their current version in /usr/bin. On ML here I can launch my version in /user/local/bin just fine. e$ which sqlite3

Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Doug Currie
On Aug 3, 2012, at 2:33 PM, Dan Kennedy wrote: > There was a problem similar to your description at one point, but > it should have been fixed before the 3.7.12 release. What do you > get from the shell command "SELECT sqlite_source_id();" on > Mountain Lion? e$

[sqlite] leap seconds

2012-07-13 Thread Doug Currie
The SQLite3 date & time functions are designed assuming > […] that every day is exactly 86400 seconds in duration. Before I start implementing TAI (or GPS time) to/from UTC translator plugin, has anyone already done this? Why? In a device that logs data with sub-second resolution, in my case a

Re: [sqlite] how to build sqlite4 (four)?

2012-06-28 Thread Doug Currie
On Jun 28, 2012, at 4:05 PM, Nico Williams wrote: > It's also possibly a good idea to just not have autoincrement. Let > the application implement it, no? After all, it can, including via > triggers. Or with PostgreSQL-style sequences

Re: [sqlite] sqlite time is 2 hours to late

2012-06-27 Thread Doug Nebeker
ay light savings. It was a painful lesson. Always store times in UTC. Doug ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] VERY weird rounding error

2012-06-17 Thread Doug Currie
On Jun 17, 2012, at 12:23 PM, Keith Medcalf wrote: > SQLITE_SIGNIFICANT_DIGITS defaults to 14, but you can override it. No matter > what is requested, the maximum number of significant digits is limited to the > specification, and rounding is applied to the remaining bits of the >

Re: [sqlite] Using SQL or C for data analysis?

2012-03-27 Thread Doug Currie
On Mar 27, 2012, at 3:46 PM, Larry Brasfield wrote: > A DBMS is a good way to keep your raw data. But I highly doubt that a > majority of your analysis algorithms are going to be expressible in SQL > without going way beyond the intended purpose of the language. You will > either find

Re: [sqlite] SQLite

2011-11-10 Thread Doug Currie
On Nov 9, 2011, at 11:39 PM, Bhautik Kothadia wrote: > Is there any Operating System Required for that? See: http://www.sqlite.org/custombuild.html especially section 5.0 Porting SQLite To A New Operating System > If not then How much Memory is required? See:

Re: [sqlite] SQLite

2011-11-09 Thread Doug Currie
The PIC32MX664F064L has 64 KiB Program Memory Size 32 KiB RAM SQLite as it presently stands will not fit within these constraints. e On Nov 9, 2011, at 7:47 AM, Parthiv Shah wrote: > Respected Sir, > > We want to use DB SQLite in our product. > > We are using PIC32MX664F064L

Re: [sqlite] triggers : NEW keyword with multiple tables

2011-10-25 Thread Doug Currie
On Oct 25, 2011, at 10:59 AM, Sébastien Escudier wrote: > CREATE TRIGGER my_trigger INSTEAD OF INSERT ON my_view > BEGIN > INSERT INTO table1(type) VALUES(NEW.table1.type); > INSERT INTO table2(type) VALUES(NEW.table2.type); > END; > > ... > > Why this syntax does not work anymore ? You

Re: [sqlite] Using modifiers in julianday function

2011-10-24 Thread Doug Currie
On Oct 24, 2011, at 11:07 AM, Dilip Ranganathan wrote: > But as you all know, this doesn't work: > > select datetime(time) from table where time >= > julianday(datetime(max(time)),'-2 hour','localtime') order by time desc Try replacing datetime(max(time)) with (select datetime(max(time)) from

Re: [sqlite] MC/DC coverage explained wrong in the home page?

2011-09-23 Thread Doug Currie
On Sep 23, 2011, at 9:17 PM, Richard Hipp wrote: > paper above completely ignores this issue. It is as if the authors had > never heard of short-circuit evaluation. Or, perhaps they are familiar with > the problem but could not reach agreement on its solution so simply didn't > bring it up.

Re: [sqlite] SQLite + unicode

2011-08-10 Thread Doug Currie
On Aug 10, 2011, at 12:39 PM, NOCaut wrote: > I work in VS2008 c++ > i create data base my.db and wont use U N I C O D E function from this DLL > i find class or unit for connect to my base from VS2008 > http://sqlite.org/download.html - this link help me? > > you understand me? No, but

Re: [sqlite] c-api

2011-07-27 Thread Doug Currie
On Jul 27, 2011, at 9:22 AM, Baruch Burstein wrote: > Is there an easier way to get a single value (for instance "select > last_insert_rowid();" ) then prepare -> step -> column -> finalize? http://www.sqlite.org/capi3ref.html#sqlite3_last_insert_rowid e

Re: [sqlite] Handle leak using IIS on windows 7?

2011-07-22 Thread Doug
This was exactly the problem; I didn't realize the 'static' variables are persisted between page views in ASP.Net Adding an '_instance = null;' fixed the issue. Thanks muchly. Cheers, Doug. On Tue, Jul 19, 2011 at 11:58 AM, Joe Mistachkin <sql...@mistachkin.com>wrote: > > A

Re: [sqlite] Handle leak using IIS on windows 7?

2011-07-18 Thread Doug
view ends the file handle is automatically released). If you want to see it in action, create a new MVC project and add: DbLogger.Get(); To the home index page. Run it in debug mode and you'll see the issue. Cheers, Doug. code (in case the attachment fails): using System; using System.Collectio

[sqlite] Handle leak using IIS on windows 7?

2011-07-18 Thread Doug
? I'm using the Precompiled Binaries for 32-bit Windows (.NET Framework 4.0) from http://system.data.sqlite.org/index.html/doc/trunk/www/downloads.wiki(32 bit mode enabled on iis), but I've tried the 64-bit version with the same result. Cheers, Doug

Re: [sqlite] OSX path

2011-06-17 Thread Doug Currie
On Jun 17, 2011, at 2:56 PM, john darnell wrote: > I am attempting to open an SQLite database on the Mac (OSX Snow Leopard) and > am getting an error. This is the code I am using: > > char DBEnginePath[1000]; > > strcpy(DBEnginePath, "Macintosh HD:Applications:Adobe InDesign >

Re: [sqlite] [BUG] Silent change in intergeral overflow handling in 3.7.6

2011-05-26 Thread Doug Currie
On May 26, 2011, at 2:54 AM, Jan Hudec wrote: > Gotcha! No, it's not. -1-x is equivalent, but -x-1 is not: > >sqlite> select -1-(1<<63), -(1<<63)-1; >9223372036854775807|9.22337203685478e+18 > > Besides my point was not that it's not possible, but that it would > be more readable with

Re: [sqlite] SQLite Explorer (singular) is missing the STDEV function (standard deviation)

2011-03-31 Thread Doug Currie
On Mar 31, 2011, at 2:27 PM, Mike Rychener wrote: > I have tried the latest Explorer and it gets a syntax error on STDEV. > However, that function works in Eclipse just fine, to take the standard > deviation of a column (like min, max, avg). Is there a workaround or > other fix available?

  1   2   3   4   >