Showing posts from January, 2007

MySQL 5.0.32: Serious InnoDB bug

In case anyone has seen spurious problems using MySQL version 5.0.32 (and presumably the identical 5.0.33 community version) you might want to take a look at MySQL Bugs #25653 and #25596 . They are about a little (but serious) InnoDB bug. If you do not yet use this version, you might consider waiting for a fixed release to become available.

Conditional INSERT with MySQL

Last week I needed to write an update SQL script that would insert some records into a database. However as the script was to be incorporated into a software update that was going to be deployed to all our customers, it needed to check some condition first and see, whether the insert was required at all. Even though MySQL provides some non-standard SQL enhancement there is no INSERT IF EXISTS kind of statement. I managed to do it using some temp-tables and a combination of INSERT IGNORE ... SELECT FROM and UPDATE ... WHERE statements. The following example demonstrates how to insert a new row of data in the table named real_table . The data must only be inserted into this table, if another record in a table named condition_table exists. No change of real_table must occur, if there is no record matching the condition. Moreover (because I needed this) the example takes take of modifying a possibly present record in real_table that already has the same primary key value as the o

MySQL 5.0.33 finally released

After some time here is another post concerning MySQL. It is not as if I had not had anything to do with MySQL in the meantime, but most of it was mailing back and forth with their customer support (which is really quite good) to get some issues resolved we stumbled over in our MySQL 4.1 to 5.0 migration. Before those were fixed we could not use MySQL 5 with our application, because there were some incompatible changes we could not work around. One of them was the unsatisfactory precision when querying DECIMALs I wrote about earlier. This is fixed in 5.0.32-enterprise and the just released 5.0.33 community edition (see Bug #23260 ). In fact I was just about to write about the new release policy which I find somewhat strange (enterprise and community editions with the enterprise releases being faster than the community ones) when I noticed that a new community release had been made public the day before yesterday. If you like to know more about this whole "edition" thing,

Google Docs to Blogger link

This is the first post to this blog that I created using Writely - sorry - Google Docs and Spreadsheets. It serves no particular purpose except to try the integration. Even though it look nice at first glance I do not believe this is something I will use anymore in the future, as all formatting is done directly with spans and individual attributes. There is no such thing as CSS integration which I have come to like very much. There are some options like Quotations that are generated as block-quotes or indentations that are just 40pixel left-margined divs. This is not a way I would like, so I guess I will be back to manual HTML editing next time :)

Java 5 crashes - the workaround

As announced I let the machine run till today - with no more crashes. The distributed GC interval was set to 4 hours. I believe we will be able to use this workaround in our production environments. Later this year we may upgrade to Java 6 which did not show the erratic behavior. Moreover, as we do not really know which combination of individual factors cause the bug to surface at all, we cannot even know for sure if there is a hardware configuration out in the field which would fail in the first place. Nevertheless, thanks for all the input and suggestions. As a roundup I will just let the machine run memtest86 for some time to make sure this is not a memory problem. However I do not believe it will show any problems for reasons stated earlier.