Hi,
Is this correct? Should update triggers not only fire for actual changes? I
have a large table with a column which contains all NULL values except for
4. I expected an UPDATE table SET column=NULL to only fire 4 triggers,
except it fires for every row.
Thanks,
Paul.
Paul van Helden wrote:
Is this correct? Should update triggers not only fire for actual changes? I
have a large table with a column which contains all NULL values except for
4. I expected an UPDATE table SET column=NULL to only fire 4 triggers,
except it fires for every row.
I'm pretty sure
On Tue, Jul 03, 2012 at 01:32:14PM +0200, Paul van Helden scratched on the wall:
Hi,
Is this correct? Should update triggers not only fire for actual changes? I
have a large table with a column which contains all NULL values except for
4. I expected an UPDATE table SET column=NULL to only
You are right, sorry, just checked. sqlite3_changes returns number of
records hit, not changed. Have been using sqlite for 2 years now and was
always under the impression this was for actual changes.
But which is better behaviour, reporting row hits versus real changes?
Especially when it comes
The statement UPDATE table SET column=NULL updates every row in the
table. The fact that some rows may already have a NULL in that
column is not important.
Well, it is important to me, the word change means before != after :-)
___
for all rows even if
sqlite3_changes returns 0
You are right, sorry, just checked. sqlite3_changes returns number of
records hit, not changed. Have been using sqlite for 2 years now and was
always under the impression this was for actual changes.
But which is better behaviour, reporting row hits versus
On Tue, Jul 3, 2012 at 2:43 PM, Paul van Helden p...@planetgis.co.zawrote:
The statement UPDATE table SET column=NULL updates every row in the
table. The fact that some rows may already have a NULL in that
column is not important.
Well, it is important to me, the word change means
On Tue, Jul 3, 2012 at 2:45 PM, Black, Michael (IS)
michael.bla...@ngc.comwrote:
What's better is that it tells you what you asked for...not what you think
you asked for...which it does.
I asked for changes :-)
You've already been shown the correct solution...a WHERE clause...
I've done
, July 03, 2012 7:47 AM
To: j...@kreibi.ch; General Discussion of SQLite Database
Subject: EXT :Re: [sqlite] Update trigger fires for all rows even if
sqlite3_changes returns 0
On Tue, Jul 3, 2012 at 2:43 PM, Paul van Helden p...@planetgis.co.zawrote:
The statement UPDATE table SET column=NULL
On Tue, Jul 3, 2012 at 3:03 PM, Black, Michael (IS)
michael.bla...@ngc.comwrote:
And Oracle says the opposite:
Yet they all give the same answer when done with update testtable set
testrow=null where testrow not null;
You keep hammering this one, it is obvious, I understand, THANKS! What
On Tue, Jul 3, 2012 at 9:21 AM, Paul van Helden p...@planetgis.co.za wrote:
So rather than holding your breath for Oracle to change I'd recommend you
do it the portable way.
I'm not waiting for anything. My last question was simple: which is
better? Since MySQL does it the correct way perhaps
On Tue, Jul 03, 2012 at 02:43:29PM +0200, Paul van Helden scratched on the wall:
The statement UPDATE table SET column=NULL updates every row in the
table. The fact that some rows may already have a NULL in that
column is not important.
Well, it is important to me, the word
On Tue, Jul 3, 2012 at 10:55 AM, Jay A. Kreibich j...@kreibi.ch wrote:
On Tue, Jul 03, 2012 at 02:43:29PM +0200, Paul van Helden scratched on the
wall:
The statement UPDATE table SET column=NULL updates every row in the
table. The fact that some rows may already have a NULL in that
On Tue, Jul 03, 2012 at 03:21:57PM +0200, Paul van Helden scratched on the wall:
On Tue, Jul 3, 2012 at 3:03 PM, Black, Michael (IS)
michael.bla...@ngc.comwrote:
And Oracle says the opposite:
Yet they all give the same answer when done with update testtable set
testrow=null where
Then why do you keep hammering on the idea that SQLite is somehow
incorrect or wrong?
You've explained what you're trying to do. We've explained there is
a better way to do that, that also happens to provide the correct
answer on all platforms, AND likely runs faster--
15 matches
Mail list logo