On 11/1/16, Mark Lawrence wrote:
> Hello all,
>
> The documentation for partial indexes (section 3.2) lists "=, <, >, <=,
> >=, <>, or IN" as operators that will trigger the use of an
> index WHERE c IS NOT NULL.
>
> It seems to me that LIKE should also be in that list, given
Thanks. I'm still unable to get SQLite 3.15.0 to fail, in any way,
using your schema and data. Do you have any further hints on how I
can cause the problem to be expressed?
Is assertion fault reliably reproduced on your system?
On 11/1/16, mark wrote:
> On Tue Nov 01, 2016 at
On Tue Nov 01, 2016 at 03:15:43PM +, Simon Slavin wrote:
>
> On 1 Nov 2016, at 3:14pm, Rob Willett
> wrote:
>
> > We use the Perl DBD module all the time. What I would expect to see
> > is [... good stuff ...]
>
> Ah, thanks for the explanation. I always had
On 1 Nov 2016, at 3:14pm, Rob Willett wrote:
> We use the Perl DBD module all the time. What I would expect to see is [...
> good stuff ...]
Ah, thanks for the explanation. I always had trouble understanding Perl's
approach to anything. Hope the OP's problem
Simon,
We use the Perl DBD module all the time. What I would expect to see is
(IGNORE THE LINE BREAKS)
my $sth = $dbh->prepare("INSERT INTO
func_begin_change(
author,
author_contact,
author_contact_method,
author_shortname,
> On 1 Nov 2016, at 2:38pm, mark wrote:
>
>VALUES
>(
>?,
>?,
>?,
>?,
>?,
>?,
>?,
>?,
>?
>)
>;
>
> At least that is what I am passing to Perl's
On Tue Nov 01, 2016 at 09:21:04AM -0400, Richard Hipp wrote:
>
> The text of the SQL that is being prepared got cut off. Can you
> please send me the complete SQL statement that is being run at the
> point of the error?
INSERT INTO
func_begin_change(
author,
sqlite> create table tbl1
...> (
...> id integer primary key autoincrement,
...> someOtherfield,
...> yetAnotherField
...> );
sqlite> create trigger trg_imInChargeAndSayNoAutoincrementUpdates
...> before update of id on tbl1
...> begin
...> select raise(abort, 'Bad
Interesting. I am using an old version, 5.5.34
The database engine may also make a difference. I was using MyISAM. INNODB may
be different.
A quick scan of the MySQL documentation suggests INNODB is different. For
example, it doesn't
store the next value in the database.
If you specify an
On 10/31/16, mark wrote:
> #18 0x17d970826118 in sqlite3RunParser (pParse=0x7f7e9200,
> zSql=0x17db9b16a600 "INSERT INTO\nfunc_begin_change(\n
> author,\nauthor_contact,\nauthor_contact_method,\n
> author_shortname,\nid,\n
Well, I got different results (so maybe it's version related). I tried it
on MySQL v5.7.16-log:
++--+
| id | v|
++--+
| 2 | two |
| 10 | one |
++--+
++--+
| id | v|
++--+
| 10 | one |
| 40 | two |
++--+
++---+
| id | v |
On 10/31/16, mark wrote:
> #3 0x17d9707fb288 in valueFromExpr (db=0x17dbbac8e808,
> pExpr=0x17dc0252b288, enc=1 '\001', affinity=68 'D',
> ppVal=0x7f7e7f08,
> pCtx=0x7f7e7f70) at sqlite3.c:70020
> #4 0x17d9707fbaa0 in stat4ValueFromExpr
On Tue Nov 01, 2016 at 02:21:02AM +0100, mark wrote:
> assertion "0" failed: file "sqlite3.c", line 70020, function
> "valueFromExpr"
I read the source code a little further and found that the NEVER at
line 70020 is actually a macro:
if( NEVER(op==TK_REGISTER) ) op = pExpr->op2;
Mark Lawrence wrote:
> The documentation for partial indexes (section 3.2) lists "=, <, >, <=,
> >=, <>, or IN" as operators that will trigger the use of an
> index WHERE c IS NOT NULL.
>
> It seems to me that LIKE should also be in that list, given that it
> will also only match when c is not
>> It remembers..
>Ah, neat. Thanks for the testing.
As a slight aside. It also never resets the value. We had a problem where the
number of inserts
had incremented the AUTO INCREMENT value to MAXINT (it took a few years). It
then stops.
We fixed it by changing id to a BIGINT, but you can
On 1 Nov 2016, at 11:44am, Andy Ling wrote:
> It remembers..
Ah, neat. Thanks for the testing. And the "show create table" command you
used makes it clear that the engine keeps a record for the table. Apparently a
single value for the table's primary key rather
It remembers..
mysql> create table tt (id int NOT NULL AUTO_INCREMENT, v TEXT, PRIMARY
KEY(id)) ;
Query OK, 0 rows affected (0.04 sec)
mysql> insert into tt (v) VALUES("one");
Query OK, 1 row affected (0.00 sec)
mysql> update tt set id=10 where v="one";
Query OK, 1 row affected (0.00 sec)
On 2016/11/01 1:01 PM, Simon Slavin wrote:
On 1 Nov 2016, at 10:45am, R Smith wrote:
D - Horrible if you up some key value significantly and then update it back
down, because there is no way the Autoinc value should *EVER* be able/allowed
to come back down. It's a
On 1 Nov 2016, at 11:14am, Andy Ling wrote:
> MySQL lets you fiddle.
I don't have MySQL. To satisfy my curiosity, could you try this:
create table tt (id int NOT NULL AUTO_INCREMENT, v TEXT, PRIMARY KEY(id)) ;
insert into tt (v) VALUES("one");
update tt set id=10
> Which, according to GB, is what some other SQL engines do: attempts to change
> a value
> in that column using UPDATE always generate an error. I didn't know that.
> I looked it up.
> Apparently Microsoft's SQLSERVER blocks it, but I was unable to find
> anything mentioning
> how any of
On 11/1/16 7:01 AM, Simon Slavin wrote:
On 1 Nov 2016, at 10:45am, R Smith wrote:
D - Horrible if you up some key value significantly and then update it back
down, because there is no way the Autoinc value should *EVER* be able/allowed
to come back down. It's a one-way
On 1 Nov 2016, at 10:45am, R Smith wrote:
> D - Horrible if you up some key value significantly and then update it back
> down, because there is no way the Autoinc value should *EVER* be able/allowed
> to come back down. It's a one-way street.
This is an additional
On 2016/11/01 11:52 AM, Simon Slavin wrote:
Unfortunately the response is going to be along the lines of "We can't do this for
compatibility reasons because there might be a program out there that does it.".
And rightly so...
There is no reason to use Autoincrement other to be sure newly
On Mon Oct 31, 2016 at 05:42:32PM -0400, Richard Hipp wrote:
> On 10/31/16, mark wrote:
> > On Mon Oct 31, 2016 at 04:04:00PM -0400, Richard Hipp wrote:
> >> Is this reproducible?
> >
> > Yes... in that I can reliably get it to segfault. Duplicating the build
> > and/or statements
On 1 Nov 2016, at 6:56am, GB wrote:
> And that is why several SQL Engines prevent AUTOINCREMENT columns from being
> UPDATEd.
I think that would be a good fix in SQLite's case. If you're relying on SQLite
to generate these unique numbers for you then you shouldn't then change
Hello all,
The documentation for partial indexes (section 3.2) lists "=, <, >, <=,
>=, <>, or IN" as operators that will trigger the use of an
index WHERE c IS NOT NULL.
It seems to me that LIKE should also be in that list, given that it
will also only match when c is not null.
I can force the
On 28 Oct 2016, at 12:47, Simon Slavin wrote:
It guess it comes down to what one wants from "INTEGER PRIMARY KEY
AUTOINCREMENT". If the requirement is only-ever-increasing then this
is a bug.
The behaviour described at https://sqlite.org/autoinc.html seems to
match this requirement:
And that is why several SQL Engines prevent AUTOINCREMENT columns from
being UPDATEd.
I think it should be fixed in the Docs, not in Code.
Richard Hipp schrieb am 31.10.2016 um 18:56:
Note that the implied purpose of AUTOINCREMENT is to generate a unique
and immutable identifier. Running
28 matches
Mail list logo