Since some builds earlier I have to fight with inserting images into tables. The problem: quotations - maybe. The one thing I could expose, that to insert an image into a blob several signs where substituted by escape characters like \n, \r, \0 and so far. It's all the problem, I think. All is need to escape an ' is a backslash - \' makes single '
Kind Regards
Quotation Bug Still Exists!?
I tried to insert an image into a table. Look at the image before inserting (view in Hex-Editor):
http://rapidshare.com/files/441797502/mppp-before.png
and this one is after inserting:
http://rapidshare.com/files/441797501/mppp-after.png
The image after inserting is bigger than before. When you look at the header of the Images you can see that few of original bytes still there, but before one original byte came one foreign. I also suggest that it could be bad conversion to Unicode and/or back.
However try to insert the image I gave and see what I mean.
Kind Regards
http://rapidshare.com/files/441797502/mppp-before.png
and this one is after inserting:
http://rapidshare.com/files/441797501/mppp-after.png
The image after inserting is bigger than before. When you look at the header of the Images you can see that few of original bytes still there, but before one original byte came one foreign. I also suggest that it could be bad conversion to Unicode and/or back.
However try to insert the image I gave and see what I mean.
Kind Regards
I just teste that, without any problem. I can insert the same file ("...before"), see it in the table, can rightclick "Image preview, and am able to save it as file again onto my harddisk, where it is again of the same file size and viewable in any image editor. So, I am probably doing something different than you, or you have an out dated release / build?
I have the latest build of HeidiSQL. Have you tried to switch to other table and back, if you still have the same information? When I just insert the image using Binary Editor -> Load binary, I can view the image too, but when I switch to other table or database, and back I get the bullshit I showed. I'll try to uninstall HeidiSQL completely then install it back. Thanks so far!
Kind Regards
Kind Regards
I already tried to reinstall the program, but with no changes. The bug is still there.
Maybe it's important to know, that inserting images using import function works as hell. Maybe it belongs to the difference, that the import function inserting the image using
the Binary Editor instead
However it makes no sense if the insertion is an UPDATE or INSERT function.
Maybe it's important to know, that inserting images using import function works as hell. Maybe it belongs to the difference, that the import function inserting the image using
INSERT INTO `database`.`table`(`blob_row`) VALUES(_binary 0x89504E470D0A)
the Binary Editor instead
INSERT INTO `database`.`table`(`blob_row`) VALUES('‰PNG\r\n')
However it makes no sense if the insertion is an UPDATE or INSERT function.
I think the clue is that parsing data using import function works because of using different code as the function for direct insert - look at the post above I wrote.
this would work
this not, but this is how it does.
You can see it below in the query history of HeidiSQL. Try it and you'll see.
this would work
INSERT INTO `database`.`table`(`blob_row`) VALUES(_binary 0x89504E470D0A)
this not, but this is how it does.
INSERT INTO `database`.`table`(`blob_row`) VALUES('‰PNG\r\n')
You can see it below in the query history of HeidiSQL. Try it and you'll see.
Please login to leave a reply, or register at first.