Brad, Edward,

> Try using 'max_allowed_packet=16M' instead of your current value.  You may also
> find help by reviewing the below.
> http://www.mysql.com/doc/en/Packet_too_large.html

That will set the communication buffer to a maximum of 16 MB, but Brad
wants more than that ... From the manual:

LONGBLOB
LONGTEXT
    A BLOB or TEXT column with a maximum length of 4294967295 (2^32 -
    1) characters. See section 6.5.3.1 Silent Column Specification
    Changes. Note that because the server/client protocol and MyISAM
    tables has currently a limit of 16M per communication packet /
    table row, you can't yet use this the whole range of this type.
    See section 6.2.3.2 The BLOB and TEXT Types.

http://www.mysql.com/doc/en/Column_types.html

Well, the manual says "currently", and it means 3.23 versions. Another
quote from the manual:

max_allowed_packet
The maximum size of one packet. The message buffer is initialised to
net_buffer_length bytes, but can grow up to max_allowed_packet bytes
when needed. This value by default is small, to catch big (possibly
wrong) packets. You must increase this value if you are using big BLOB
columns. It should be as big as the biggest BLOB you want to use. The
protocol limits for max_allowed_packet is 16M in MySQL 3.23 and 1G in
MySQL 4.0.

http://www.mysql.com/doc/en/SHOW_VARIABLES.html

So Brad must use MySQL >= 4.0.0, and add this to his configuration
file to be able to store blobs up to 1 GB in size:

max_allowed_packet=1G

> Is there a reason you are including the BLOBs in the database instead of just
> linking via it?  I know it's generally considered better practice to do the
> latter.

Like always, that's true.

Regards,
--
  Stefan Hinz <[EMAIL PROTECTED]>
  iConnect GmbH <http://iConnect.de>
  Heesestr. 6, 12169 Berlin (Germany)
  Telefon: +49 30 7970948-0  Fax: +49 30 7970948-3

[filter fodder: sql, mysql, query]


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to