Login
You're viewing the functional.cafe public feed.
  • Nov 3, 2026, 1:43 PM

    @tommorris to give a taste of the state of MySQL at the time (now long ago), the guts of a storage engine was a function to get the next row in the table, which returned a flag to signal end of table. We implemented it and it worked right up until we tested joins, where we (through stepping with a debugger and inspecting other table engine source) found there was also an undocumented global errno-like value that could be used to signal end of table, which was ignored in normal table scans but...

    💬 1🔄 0⭐ 0

Replies

  • Nov 3, 2026, 1:46 PM

    @tommorris ...the nested loop that implemented joins checked for it. Our code never set it so when a MyISAM table in a join with us ran out of rows and signalled it, our table was seen as out of rows too.

    There were several other "different data paths used for the same thing in different contexts", where any inconsistency between them would (a) be easily done and (b) cause really weird behaviour that only crops up in certain combinations of situations, it was a real train wreck!

    💬 1🔄 0⭐ 0
  • 💬 0🔄 0⭐ 0