semi-OT : mySQL oddities

jbv jbv at
Wed Nov 28 03:58:41 EST 2018

Hi list,
This is a quick follow-up to my post from a couple of months ago.
After weeks of tweeking and testing, I am now 99.99% sure there's
an issue with auto-increment in the latest versions of mySQL, at
least with large tables with several indexes and complex scripts
that insert and update several rows in one pass.

Long story short, I finally removed auto-increment on a primary
key (integer) and added the following lines to my script (pseudo code) :
  select MAX(id) from myTable limit 1
  put it into tMaxID
  add 1 to tMaxID

I've been watching & checking the table content for several weeks,
and random duplicates / corruption of rows have totally disappeared.
I hope I found the solution, but will keep checking.
I also thing I will bypass auto-increment in future projects.

All the best,

On Tue, October 9, 2018 10:13 pm, jbv via use-livecode wrote:
> Hi list,
> I'm not 100% sure yet, but I think I'm experiencing some problems with
> mySQL 5.6.41 and LC server, the most annoying one being random duplicate
> entries in some tables, especially the biggest ones, for instance 71 Mb
> and nearly 140000 entries. I have searched the web for more info and have
> found a few posts on stackoverflow and some other blogs mentioning
> problems with autoincrement, but the symptoms are slightly different... I
> was wondering if anyone had experienced similar issues ?
> Thanks in advance.
> Best,
> jbv
> _______________________________________________
> use-livecode mailing list use-livecode at Please visit this
> url to subscribe, unsubscribe and manage your subscription preferences:

More information about the use-livecode mailing list