I've now worked it out. I eventually decided to restart my computer on the off chance that MySQL wasn't actually reconfiguring after I set max_allowed_packet (even though it seemed this shouldn't actually affect things since I was only changing from 1M to 32M, and my query seems to be less than 1M). This fixed the problem.
It seems odd to me that I should need to restart my computer to get MySQL to recognise the change - I did restart my server after the config change to 32M, so I expected the connection made to MySQL to use the 32M packet size. If anyone knows how to configure MySQL to not require computer restarts (this is in Vista), that would be good to know. Even stranger is that with a supposed limit of 1M, the following code - puts blobstring.class puts blobstring.length Record.new(:field_1 => integer_1, :field_2 => integer_2, :field_3 => word, :field_4 => integer_4, :blob_field => blobstring).save outputs: String 834880 and causes a "MySQL has gone away" error, on response to the MySQL insert command caused by the "save" call above, yet with max_allowed_packet=32M, it works fine. Maybe there are is more than just the query string itself contributing to the 1 megabyte? - Farmer - Farmer -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

