URGENT!! Image Data Backup under Win7 x86 cannot be properly restored under Win7 x64

[expired user #7020]'s profile image [expired user #7020] posted 11 years ago in General Permalink
I have recently re-installed Win7 at x86. An important database has been backup using "export database as SQL" function. Tested and worked under original Win7 x86 setting.

After the re-installation of Win7 x64, I have loaded the back-up file as SQL into the DB, but noticed the size of the database is 50% smaller compared to before. NONE of the JPG image in the DB after loading(out of 650 images saved in the database) is readable/displayable any more.

To test the issue, I have loaded a test image under x64 and read successfully using the same php code, which means the php code I have is fine and there is something right with the binary image text stored down. All text data are fine.

Please help to fix.

At the moment, I am going to try under a VM that build under Win7 x86 to retrieve to data.....


[expired user #7020]'s profile image [expired user #7020] posted 11 years ago Permalink
tested under virtual environment under Win7 x86 cannot read the image either......
[expired user #7020]'s profile image [expired user #7020] posted 11 years ago Permalink
looks like an issue with export and import function itself. It doesn't work with image. I have tried to load a few test image into the BD and do the back up. Re=load the image the binary texts are not the same as the original DB.
ansgar's profile image ansgar posted 11 years ago Permalink
The Windows version is pretty unimportant here. What's more important:
* HeidiSQL revision
* MySQL Sever version (while export, and on your new Windows)
* How the export was done: Did you check "Create" and "Drop" tables?
[expired user #7020]'s profile image [expired user #7020] posted 11 years ago Permalink
For export/backup:
HeidiSQL versionL 8.0.0.4396
SQL Server version:5.5.24

For import:
HeidiSQL versionL 8.0.0.4396
SQL Server version:5.5.24

Backup procedure:
Only tick "create" for both option and INSERT.

[expired user #7020]'s profile image [expired user #7020] posted 11 years ago Permalink
Something really strange, the binary code changed in the SQL back up

e.g. "0xFFD8FFE000104A46494600010101004800480" from original image
will change to
"0xFF3F3F00104A46494600010101004800480" in the SQL backup, no matter what I do.

[expired user #7020]'s profile image [expired user #7020] posted 11 years ago Permalink
If can copy the same binary text string into a new field, it doesn't work as well. It looks to me that make the image readable, the only way is to load the image directly into the DB.

Any help...?
[expired user #7020]'s profile image [expired user #7020] posted 11 years ago Permalink
The same image in binary text using loading function:
FF3F3F00104A46494600010101004800480000FF3FB245...

From the SQL backup (with 6 more zero at the end):
FF3F3F00104A46494600010101004800480000FF3FB245...

Please login to leave a reply, or register at first.