Dennis Wu wrote:

> I have a table with a column defined as BLOB. However, when I dump 
> this table using ./mysqldump, the dump file cannot be imported. Is 
> that because a binary field cannot be dumped into a text file? Any 
> solution if I really need to do the backup by dumping the table?


When you say "cannot be imported" - what happens? Does the import happen, 
but incorrectly (i.e. BLOB contents change)? Does mysql fail to process the 
import at all (what error message)? Does it crash? Sing the Star Spangled 
Banner? What?

If it is the first situation (BLOB restored, but incorrectly), check out 
the warning in "mysqldump --help":

  -r, --result-file=... Direct output to a give file. This open should be
                        used in MSDOS, because it prevents newline '\n'
                        from being converted to '\n\r' (newline + carriage
                        return).

(For MSDOS, read "Windows" as well..)

You can do the import the usual way:

   mysql ..options.. < dump.file

--
Shankar.


---------------------------------------------------------------------
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