| Bug #6917 | Refuse to insert into mediumblob field large values | ||
|---|---|---|---|
| Submitted: | 1 Dec 2004 15:14 | Modified: | 7 Feb 2005 11:13 |
| Reporter: | Ilya Denisov | Email Updates: | |
| Status: | Can't repeat | Impact on me: | |
| Category: | MySQL Server | Severity: | S3 (Non-critical) |
| Version: | 4.1.7-log | OS: | Windows (Windows XP) |
| Assigned to: | CPU Architecture: | Any | |
[7 Feb 2005 11:13]
Hartmut Holzgraefe
Can't reproduce using latest PHP source and MySQL 4.1.8 on Linux.

Description: I use php v. 5.0.3.3. Command: .... $file_buf=base64_encode($file_buf); $sql="update documents set doc_file='".$file_buf."' where reg_id='$reg_id'"; $result = mysql_query($sql); returns string: 2006: MySQL server has gone away. The doc_file field is of mediumblob type. For previous version of MySQL (4.0.21) variable in my.ini: max_allowed_packet=8M (instead of default 1M) resolves the similar problem but with the new vers. of MySQL that did't work. I have found the critical length of variable that allow to be place into fiels doc_file. That is 241564 bytes. How to repeat: No idea. Use together with the last version php.