Re: high concurency issue with read-write on mysql table
I tried to use Delete chunk's but the script on the link won't work:
set @a = 0
LOOP
DELETE FROM tbl
WHERE id BETWEEN @a AND @a+999
AND ts < DATE_SUB(CURRENT_DATE(), INTERVAL 30 DAY)
SET @a = @a + 1000
sleep 1 -- be a nice guy
UNTIL end of table
It told me 'Syntax error ...' near LOOP.
I tried to do it on stored routines but I got the same error.
what's wrong with that script?
Subject
Views
Written By
Posted
1289
June 12, 2017 05:56AM
618
June 12, 2017 11:09AM
639
June 13, 2017 05:22AM
600
June 13, 2017 10:02AM
Re: high concurency issue with read-write on mysql table
750
June 14, 2017 06:42AM
588
June 14, 2017 09:20AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.