On 16.02.2001 10:05:54 I.SivaramaKrishnan wrote:

> Hi all,
>
> Basically I have a requirement where I have to store xml files in the
database.
> The table that I visualised for the purpose will contain two columns, one
being
> the key (varchar) and the other for the xml file.  What data type should I use
> for the second column.

I always use a MEDIUMTEXT type for this, see:
http://www.mysql.com/doc/C/o/Column_types.html .  Although the column allows you
to store 16 MB of data, it maybe that you need to start mysqld with a larger max
packet size, as the default is 1 MB, which may not be enough.

Further, I store the values base64 encoded in the column, so that I don't need
to take care of special characters like ', " or \0.  This will also increase the
datasize by about 33%.



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to