Announcement

Collapse
No announcement yet.

Restoring database - problem with image attachments.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Restoring database - problem with image attachments.

    I didn't know where to post this question, here or in the mysql forum?

    The problem I seem to have is any attached images shown within a thread or Avatars uploaded by users cause problems when restoring a backup of the database. Mysql reports that there is a problem with the database on line x at line 1, with some odd charators etc.

    I am dumping the database using Admin CP to a a file such as 'dump.sql'

    I have hands on access to the server and am using DOS command promt to restore data i.e.

    C:\mysql\bin\mysql\mysql forums < C:\backup\dump.sql

    I can sort the problem out by opening the dump.sql file in a text editor and deleting all the odd charators saving it and then re-run the DOS command.

    I see lots of VB forums with attached images within threads and custom animated avators so I am asuming there is an easier way then editing the backup file if a restore is necessary?!

    Has anybody any advise. Be warned I am a newbie to this and I am trying to learn as much possible!

    Thanks

    Steve.

  • #2
    Try dumping your database with this command:
    Code:
    mysqldump -uusername -ppassword databasename > path/to/dump.sql
    That's what I use and it works great.
    Chen Avinadav
    Better to remain silent and be thought a fool than to speak out and remove all doubt.

    גם אני מאוכזב מסיקור תחרות לתור מוטור של NRG הרשת ע"י מעריב

    Comment


    • #3
      Sorted - Thanks Firefly!

      Comment

      widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
      Working...
      X