I ran across this page:
https://sqlite.org/speed.html
It is a 'bit' outdated. (It uses 2.7.6.) Where can I find the scripts? And
would it be a lot of work to update them and regularly rerun them? If it is
manageable I would not mind to provide regularly updates.
--
Cecil Westerhof
Op vr 27 dec. 2019 om 17:01 schreef Simon Slavin :
> On 27 Dec 2019, at 3:06pm, Cecil Westerhof wrote:
>
> > My applications only use one thread (for the db stuff). Would it be a
> good idea to switch to single-thread mode, or does that not give a real
> performance improvement
when I switch to
multiple threads.
Maybe a good idea to add something about that at:
https://www.sqlite.org/threadsafe.html
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin
ot expect to insert records from the
past), but I also add that it will not be higher as record from a later
date.
-Ursprüngliche Nachricht-
> Von: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org]
> Im Auftrag von Cecil Westerhof
> Gesendet: Freitag, 27. D
SummaryUdemy
;
If this can be done better: let me know.
Normally speaking total and completed should never decrease. It is not
really important, but just as an exercise: is it possible to add
constraints so that you cannot enter a total, or a completed that is lower
as the previous one?
--
Cec
, Maximum
, Maximum - Minimum AS Range
FROM (
SELECT MIN(totalUsed) AS Minimum
, MAX(totalUsed) AS Maximum
FROM quotes
)
Is this acceptable, or could there be unintended consequences? Is there a
better way to do it?
--
Cecil Westerhof
code, but I was wondering if this could be done
with a SQL statement.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2018-09-02 17:31 GMT+02:00 Simon Slavin :
> On 2 Sep 2018, at 2:43pm, Cecil Westerhof wrote:
>
> > When I do in sqlitebrowser:
> >PRAGMA TABLE_INFO(messages)
>
> Just for peace of mind, since you are reporting unexpected behaviour,
> please run an integrity_check.
to the database. So I added a checkpoint to the end of my programs
also.
Any idea why this happens?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
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-
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 &quo
more efficient. ;-)
> sqlite> select x from x where x between 1 and 10;
> QUERY PLAN
>
I should learn to read QUERY PLAN's.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.o
second better.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
t back. That is why I do my statistics after two in the morning.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2018-08-29 21:26 GMT+02:00 Wout Mertens :
> By the way, why not store the time as epoch? Date and time in one...
>
Because I think it is better to have date and time as different (text)
fields.
--
Cecil Westerhof
___
sqlite-users mailing list
2018-08-29 18:58 GMT+02:00 Cecil Westerhof :
> 2018-08-29 18:06 GMT+02:00 R Smith :
>
>>
>> SELECT SUM(Tot) AS Tot, SUM(Late) AS Late
>> FROM (SELECT 1 AS Tot, (time NOT LIKE '%:00') AS Late
>> FROM messages
>> WHERE date = DATE('now')
&
WHERE date = DATE('now')
)
)
> On 2018/08/29 5:56 PM, Cecil Westerhof wrote:
>
>> I have a table messages in which something is put every minute. The total
>> messages that are added today I can get with:
>> SELECT COUNT(*) AS Total
>>
with:
SELECT COUNT(*) AS Late
FROM messages
WHERE date = DATE('now')
AND time NOT LIKE '%:00'
Is there a way to get this information in one query?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
2018-07-30 20:39 GMT+02:00 Cecil Westerhof :
> I described the problem here:
> http://paste.tclers.tk/4800
>
The solution is a CAST:
AND Temperature > CAST(:tempAbove AS real)
--
Cecil Westerhof
___
sqlite-users mailing
I described the problem here:
http://paste.tclers.tk/4800
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2018-07-19 11:37 GMT+02:00 R Smith :
> On 2018/07/19 8:35 AM, Cecil Westerhof wrote:
>
>> I have the following Tcl code:
>> set rollback "
>> INSERT OR REPLACE INTO pipRollback
>> (pipType, package, old, new)
>> VALUES
>> (
${doAppend}} {
append packages "${package} "
db eval ${rollback}
}
}
db eval {COMMIT TRANSACTION}
I suppose it is the correct way, but is there something I should change?
--
Cecil Westerhof
___
sqlite-users
2018-07-12 9:30 GMT+02:00 Cecil Westerhof :
> A few tables have a not completely apt named column totalUsed.
>
> It is used to see which records are more used as other records and give
> the less used records a bigger chance of being selected. When the numbers
> become high I do
(totalUsed) FROM tips) + 1
I am not quit happy with this. Would it be better to split it in two
queries and feed the result of the first to the second?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http
users [mailto:sqlite-users-boun...@mailinglists.sqlite.org]
> Im Auftrag von Cecil Westerhof
> Gesendet: Montag, 09. Juli 2018 08:21
> An: SQLite mailing list
> Betreff: [EXTERNAL] [sqlite] What happens when a call contains two SQL
> statement
>
> I am working with Tcl. The best is
sting
(key, value)
VALUES
(12, 'Just some text')
"
db eval ${sqlCmd}
If the insert goes wrong, will the delete be rolled back, or not?
I could use INSERT OR REPLACE, but the above code would be database
independent.
--
Cecil
2018-07-08 11:00 GMT+02:00 Cecil Westerhof :
> 2018-07-08 8:19 GMT+02:00 Cecil Westerhof :
>
>> I thought there was a problem with RANDOM. I used:
>> ,ABS(RANDOM()) / CAST(1.4E18 AS INTEGER) AS Randomiser
>>
>> And it seemed I got a lot of thre
2018-07-08 8:19 GMT+02:00 Cecil Westerhof :
> I thought there was a problem with RANDOM. I used:
> ,ABS(RANDOM()) / CAST(1.4E18 AS INTEGER) AS Randomiser
>
> And it seemed I got a lot of threes.
>
> To check this I used:
> SELECT Randomiser
> ,
sqlite-users [mailto:sqlite-users-
> >boun...@mailinglists.sqlite.org] On Behalf Of Cecil Westerhof
> >Sent: Sunday, 8 July, 2018 02:16
> >To: SQLite mailing list
> >Subject: Re: [sqlite] Kind of pivot table
> >
> >2018-07-08 9:10 GMT+02:00 Keith Medcalf :
> &
when I try the first
statement I get:
Error: no such table: generate_series
Am I overlooking something?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
D, quote (with extra line(s)) and lastUsed.
Is this an acceptable way to implement it, or would it be better to unravel
the elements in different records?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
ailto:sqlite-users-
> >boun...@mailinglists.sqlite.org] On Behalf Of Cecil Westerhof
> >Sent: Sunday, 8 July, 2018 00:44
> >To: SQLite mailing list
> >Subject: Re: [sqlite] Kind of pivot table
> >
> >2018-07-08 8:19 GMT+02:00 Cecil Westerhof :
> >
> >> I thought there wa
2018-07-08 8:19 GMT+02:00 Cecil Westerhof :
> I thought there was a problem with RANDOM. I used:
> ,ABS(RANDOM()) / CAST(1.4E18 AS INTEGER) AS Randomiser
>
> And it seemed I got a lot of threes.
>
> To check this I used:
> SELECT Randomiser
> ,
uot;3""165727"
"4""165619"
"5""165749"
"6""98042"
So 6 is created less often as 0 - 5, but that is in my use case not a
problem.
This worked for me because I have a big table CPUUsage. But if I would
2018-07-07 14:57 GMT+02:00 Simon Slavin :
> On 7 Jul 2018, at 12:04pm, Cecil Westerhof wrote:
>
> > I went for the following solution:
> >UPDATE
>
>
> selectRandom
> >SETlastUsed= DATE('now', 'localtime')
> >, lastU
2018-07-05 5:37 GMT+02:00 Simon Slavin :
> On 5 Jul 2018, at 3:22am, Cecil Westerhof wrote:
>
> > I only want to store a date with a record. But it is possible that more
> as
> > one record will be inserted, so I want to use another field to use as an
> > index. So
2018-07-05 5:37 GMT+02:00 Simon Slavin :
> On 5 Jul 2018, at 3:22am, Cecil Westerhof wrote:
>
> > I only want to store a date with a record. But it is possible that more
> as
> > one record will be inserted, so I want to use another field to use as an
> > index. So
the highest index and increase this with one?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
(totalUsed) AS Maximum
, MAX(totalUsed) - MIN(totalUsed) AS Range
FROM quotes
Or is there a reason to go for the second query, or even a total different
query?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users
2018-06-12 12:38 GMT+02:00 Clemens Ladisch :
> Cecil Westerhof wrote:
> > I want to create a field that only has values that consist of letters,
> > numbers end '-'. So no spaces, quotes or special characters like: '@%$!'.
> > What is the best way to write this check con
I want to create a field that only has values that consist of letters,
numbers end '-'. So no spaces, quotes or special characters like: '@%$!'.
What is the best way to write this check constraint?
--
Cecil Westerhof
___
sqlite-users mailing list
2018-05-11 11:12 GMT+02:00 Cecil Westerhof <cldwester...@gmail.com>:
> 2018-05-10 1:09 GMT+02:00 Simon Slavin <slav...@bigfraud.org>:
>
>>
>>
>> On 9 May 2018, at 9:37pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
>>
>> > I am
2018-05-10 1:09 GMT+02:00 Simon Slavin <slav...@bigfraud.org>:
>
>
> On 9 May 2018, at 9:37pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
>
> > I am bitten by it also now. I posted a question and within two minutes I
> > got a spam message
>
> I
n my message.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
,COUNT(*)AS NoUsed
FROM quotes
WHEREtotalUsed == 'unused'
UNION ALL
SELECT 'Total' AS Type
,COUNT(*) AS NoUsed
FROM quotes
)
WHERENoUsed > 0
Is this correct, or is there a better way?
--
Cecil Wester
our overall schema. You might compute this using:
>
>sqlite3 yourfile.db '.schema --indent' | grep -i autoincrement | wc -l
>
A lot less as I thought:
0
5
0
0
0
0
0
0
0
2
0
2
0
0
0
1
0
0
0
--
Cecil Westerhof
___
sqlit
2018-03-11 9:49 GMT+01:00 Clemens Ladisch <clem...@ladisch.de>:
> Cecil Westerhof wrote:
> > I see that in certain older queries I use:
> > LIMIT (SELECT COUNT(*) FROM TABLE)
> >
> > It looks like this has no use (limiting the selected rec
quot;15.580638189131""2.0146022387495"
"Zoals het klokje thuis tikt,
tikt het nergens.""2017-01-18""8.53059705262686"
"15.7307229942" "1.1516802288132"
So randomiser is not stable any-more.
For the moment
I see that in certain older queries I use:
LIMIT (SELECT COUNT(*) FROM TABLE)
It looks like this has no use (limiting the selected records to the
number of records there are). Anyone an idea what could be a reason for
this?
--
Cecil Westerhof
On 2/1/18, 2:25 PM, "sqlite-users on behalf of Cecil Westerhof" <
> sqlite-users-boun...@mailinglists.sqlite.org on behalf of
> cldwester...@gmail.com> wrote:
>
> At the moment I have a script where I send the output of a ffmpeg
> command
> to the terminal
2018-02-01 21:42 GMT+01:00 Simon Slavin <slav...@bigfraud.org>:
> On 1 Feb 2018, at 8:25pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
>
> > At the moment I have a script where I send the output of a ffmpeg command
> > to the terminal and a file. Is it possible
At the moment I have a script where I send the output of a ffmpeg command
to the terminal and a file. Is it possible to send the output to a SQLite
table. I like to use tcl for this.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users
here:
https://wiki.tcl.tk/54781
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
that is cohesive over any problem domain other than that covered
> by the example, and your referential constraints are inadequate to ensure
> integrity for your limited example.
>
I think I can solve it generally. I will look into it and share it here.
> >-Original Messa
irection, but I am thinking I am going to
do it programmatically. Maybe write a general function for it.
Everyone thanks for the fast replies.
> -Original Message-
> From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org]
> On Behalf Of Cecil Westerhof
> Se
2018-01-22 23:07 GMT+01:00 Igor Tandetnik <i...@tandetnik.org>:
> On 1/22/2018 4:36 PM, Cecil Westerhof wrote:
>
>>
>> When I do this, I get:
>> sqlite> SELECT *
>> ...> FROM playYouTubeVideo
>> ...> WHERE key BETWEEN '1' AND '5'
>
>>
>> -Original Message-
>> From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org]
>> On Behalf Of Cecil Westerhof
>> Sent: Monday, January 22, 2018 3:30 PM
>> To: SQLite mailing list
>> Subject: [sqlite] Can this be do
so, when the range becomes big, it will be a lot of code.
I was hoping I overlooked a smart trick, but I probably need to do it
programmatically.
-Original Message-
> From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org]
> On Behalf Of Cecil Westerhof
> Sent: Monday, Janua
mmatically, or can this be done
with SQL?
And optionally also:
- The value by key '1' becomes the value by key '5'.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listi
-+--
42.0 |96
41.5 | 161
41.0 |96
40.5 | 8
-----+------
SubTotal | 361
-+--
Total | 1440
-+--
If people are interested I can share some more.
--
Cecil Wes
I was looking at:
Tcl'2017 - SQLite's use of Tcl (Richard Hipp)
There is talk about the sqlite3_analyzer. But I do not have this on my
Debian system. Is that only for Windows?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users
2017-12-06 15:46 GMT+01:00 Peter Da Silva <peter.dasi...@flightaware.com>:
> I’d recommend expr {double($temp)} so the bytecode compiler can optimize
> the expression.
>
> On 12/6/17, 8:40 AM, "sqlite-users on behalf of Cecil Westerhof" <
> sqlite-users-boun...
2017-12-06 14:58 GMT+01:00 Simon Slavin <slav...@bigfraud.org>:
>
>
> On 6 Dec 2017, at 1:19pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
>
> >message NOT NULL
>
> Given thqt you want the "message" stored as REAL
ence.
On Wed, Dec 6, 2017 at 11:09 AM, Cecil Westerhof <cldwester...@gmail.com>
> wrote:
>
> > I have the following tcl script:
> > #!/usr/bin/env tclsh
> >
> > ### Improvements
> > # Get database from conf-file
> >
> >
> >
type = 'cpu-temp'
AND date = '2017-12-06'
I see that the temperature is saved as text.
In the past I had a script like this in Python who would save the
temperature as real. What do I need to change to let this script save it as
real also?
--
Cecil Westerhof
___
2017-12-04 14:33 GMT+01:00 Cecil Westerhof <cldwester...@gmail.com>:
>
>
> 2017-11-19 23:00 GMT+01:00 jungle boogie <jungleboog...@gmail.com>:
>
>> Thus said Cecil Westerhof on Sat, 18 Nov 2017 14:43:23 +0100
>>
>>> I found the benefits for
aluating {exec {swapon --noheadings --show}}
or:
exec swapon {--noheadings --show}
swapon: unrecognized option '--noheadings --show'
On Dec 4, 2017 8:27 AM, "Cecil Westerhof" <cldwester...@gmail.com> wrote:
>
> > 2017-12-04 15:24 GMT+01:00 Gerry Snyder <mesmerizer...@gma
2017-12-04 15:24 GMT+01:00 Gerry Snyder <mesmerizer...@gmail.com>:
> It is always a good idea to put the arguments of [expr] in braces. That way
> they are byte-compiled.
>
You mean like:
exec {swapon} (--noheadings} {--show}
--
2017-11-19 23:00 GMT+01:00 jungle boogie <jungleboog...@gmail.com>:
> Thus said Cecil Westerhof on Sat, 18 Nov 2017 14:43:23 +0100
>
>> I found the benefits for TCL/TK. But this is a SQLite mailing list, so not
>> the right place to ask questions if it is not connected
2017-11-18 15:14 GMT+01:00 Eric <e...@deptj.eu>:
> On Sat, 18 Nov 2017 14:43:23 +0100, Cecil Westerhof <
> cldwester...@gmail.com> wrote:
> > I found the benefits for TCL/TK. But this is a SQLite mailing list, so
> not
> > the right place to ask questions if i
I found the benefits for TCL/TK. But this is a SQLite mailing list, so not
the right place to ask questions if it is not connected to SQLite also.
What would be good resources for TCL/TK?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users
FROM (
SELECT *
,abs(random()) / CAST(1.4E18 AS INTEGER) AS Randomiser
FROM teaInStock
ORDER BY LastUsed
)
ORDER BY randomiser + IFNULL(JULIANDAY(LastUsed), 0) ASC
LIMIT:limitNr
"
--
Cecil Wester
2017-11-17 12:43 GMT+01:00 Cecil Westerhof <cldwester...@gmail.com>:
> I have the following:
> set getLatestTeasStr {
> SELECT Tea
> FROM teaInStock
> ORDER BY LastUsed DESC
> LIMIT5
> ;
> }
>
> Bu
FROM teaInStock
ORDER BY LastUsed DESC
LIMIT?
;
}
In Java I would do something like:
psSel.setInt(1, nrToFetch);
How do I do this in TCL?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users
In Bash I can use:
continue 2
to continue not the current loop, but the loop surrounding it.
This does not work in TCL. Is there another way to do this?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http
xpr ${i} + 1] \
[dict get [lindex $teaList ${i}] Tea] \
[dict get [lindex $teaList ${i}] LastUsed] \
[dict get [lindex $teaList ${i}] Location] \
[dict get [lindex $teaList ${i}] Randomiser]]
incr i
}
This does what
2017-11-17 9:38 GMT+01:00 Dan Kennedy <danielk1...@gmail.com>:
> On 11/17/2017 03:20 PM, Cecil Westerhof wrote:
>
>> The folowing works:
>> db eval ${getTeasToDrinkStr} {
>> puts [format "%-30s %-10s %2s %d" ${Tea} ${Last Used} ${Location}
&
ng instead of an array. How do I get it filled as an
array?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2017-11-17 5:38 GMT+01:00 Cecil Westerhof <cldwester...@gmail.com>:
> setsqliteVersion [sqlite3 -version]
>
By the way, I think it is a good idea to amend:
https://sqlite.org/tclsqlite.html
to show this possibility.
--
Cec
2017-11-16 22:20 GMT+01:00 Richard Hipp <d...@sqlite.org>:
> On 11/16/17, Cecil Westerhof <cldwester...@gmail.com> wrote:
> > Is it possible to get the library version before connecting to a
> database?
>
> puts [sqlite -version]
>
Combining yours and Eric's ve
?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2017-11-16 18:44 GMT+01:00 Peter Da Silva <peter.dasi...@flightaware.com>:
>
> On 11/16/17, 11:37 AM, "sqlite-users on behalf of Cecil Westerhof" <
> sqlite-users-boun...@mailinglists.sqlite.org on behalf of
> cldwester...@gmail.com> wrote:
> > Wh
aInStock} {
puts $Tea, $Location
}"
I would like something like:
Brandnetel 2017-11-16 1
Oolong 2017-10-29 2
Goudsbloem 2017-10-22 3
Jasmijn …
And probably another complication: one of the columns is called: "Last
Used".
--
Cecil Westerhof
2017-11-06 11:11 GMT+01:00 Cecil Westerhof <cldwester...@gmail.com>:
> 2017-11-06 10:39 GMT+01:00 Keith Medcalf <kmedc...@dessus.com>:
>
>>
>> The easiest way is likely to make the query so that it cannot be
>> flattened by adding an ORDER BY (that does no
“DB Browser for SQLite” which uses 3.15.2.
I am not sure in which programming language the real version will be
implemented, but it will probably use a version near that one. For example
my Java uses 3.20.0.
> >-Original Message-
> >From: sqlite-users [mailto:sqlite-users-
> >boun...@mai
uot;2458047.5"
"2017-10-17""2" "5""2458048.5"
"2017-10-20""3""1""2458048.5"
Is there a way to generate Randomiser in such a way it is only calculated
once pro record?
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2017-09-07 0:57 GMT+02:00 Simon Slavin <slav...@bigfraud.org>:
>
>
> On 6 Sep 2017, at 11:31pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
>
> > 2017-09-07 0:20 GMT+02:00 Richard Hipp <d...@sqlite.org>:
> >
> >> On 9/6/17, Cecil Westerh
2017-09-07 0:36 GMT+02:00 Wolfgang Enzinger <sql...@enzinger.net>:
> Am Thu, 7 Sep 2017 00:28:56 +0200 schrieb Cecil Westerhof:
>
> > 2017-09-07 0:20 GMT+02:00 Wolfgang Enzinger <sql...@enzinger.net>:
>
> >> Add this trigger and everything i
TRAINT float CHECK(TYPEOF(float) IN ("real","integer"))
);
Instead of "int" you need "integer".
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
2017-09-07 0:20 GMT+02:00 Richard Hipp <d...@sqlite.org>:
> On 9/6/17, Cecil Westerhof <cldwester...@gmail.com> wrote:
> >
> > Maybe this is correct, but it is certainly confusing.
> >
>
> The constraint check occurs before the implicit conversion.
>
2017-09-07 0:20 GMT+02:00 Wolfgang Enzinger <sql...@enzinger.net>:
> Am Thu, 7 Sep 2017 00:15:39 +0200 schrieb Cecil Westerhof:
>
> > 2017-09-07 0:05 GMT+02:00 R Smith <rsm...@rsweb.co.za>:
> >
> >> On 2017/09/06 11:58 PM, R Smith wrote:
> >>
d do:
INSERT INTO testing
(float)
VALUES
(0)
The insert is successful of-course.
When I then execute:
SELECT float, TYPEOF(float)
FROM testing
I get:
"0.0""real"
Maybe this is correct, but it is certainly confusing.
--
Cecil Westerhof
___
2017-09-06 23:58 GMT+02:00 R Smith <rsm...@rsweb.co.za>:
> On 2017/09/06 11:37 PM, Cecil Westerhof wrote:
>
>> But should in the first case the 0 not be cast to a 0.0?
>>
>
> What makes you believe SQLite should massage the data into specific types
> for you wit
2017-09-06 23:49 GMT+02:00 Jens Alfke <j...@mooseyard.com>:
>
>
> > On Sep 6, 2017, at 2:37 PM, Cecil Westerhof <cldwester...@gmail.com>
> wrote:
> >
> > But should in the first case the 0 not be cast to a 0.0?
>
> No, SQLite ignores colu
ing
(float)
VALUES
(0.0)
I get:
Query executed successfully
But should in the first case the 0 not be cast to a 0.0?
I do this in DBBrowser which uses 3.15.2.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlit
2017-09-06 12:54 GMT+02:00 Andy Ling <andy.l...@s-a-m.com>:
> > Cecil Westerhof wrote:
> > > I am thinking about writing some Android applications. I would like to
> > > share data between the phone (or tablet) and de desktop. What is the
> best
> > >
2017-09-06 12:01 GMT+02:00 Andy Ling <andy.l...@s-a-m.com>:
> Cecil Westerhof wrote:
> > I am thinking about writing some Android applications. I would like to
> > share data between the phone (or tablet) and de desktop. What is the best
> > way to do this? In a way th
2017-09-05 23:11 GMT+02:00 Simon Slavin <slav...@bigfraud.org>:
>
>
> On 5 Sep 2017, at 9:21pm, Cecil Westerhof <cldwester...@gmail.com> wrote:
>
> > I want to know the number of teas I have in stock. For this I use:
> > SELECT COUNT(Tea)
> > FROM
ntil the OP mentioned his Tea column cannot have NULL
> values, so now I'm slightly lost and Stephen's interpretation seems more
> sensible, but then the OP said that Igor's solution is working for him,
> which should only work if there are NULL values... so yes, I am very much
&g
ss
> roundabout way.
Yes, your query is the better one.
--
Cecil Westerhof
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
1 - 100 of 350 matches
Mail list logo