Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > DBI Mysql storing DBI:binary, trouble with character 26

Thread Tools

DBI Mysql storing DBI:binary, trouble with character 26

Jerome Hauss
Posts: n/a
Content-Type: text/plain;
Content-Transfer-Encoding: quoted-printable


Is there any solution to get binary data stored in a correct way into a =
blob in a Mysql database on a win32 platform ?

I am trying to store data from Ruby into a mysql LONGBLOB column, on a =
Win32 platform (Windows 2000, dbi 0.0.23 with Ruby/MySQL 0.2.5 =
interface, ruby 1.8.10-1, mysql 4.0.21)
From ruby-dbi-all-0.0.23.tar.gz archive, I have tested =
ruby-dbi-all\lib\dbd_mysql\test\blob_test.rb, and it appears character =
26 (octal 032) (hexa 1A) (CTRL-Z) stored in a blob is retrieved as =
character 90 (octal 132) (hexa 5A) (Z itself). All tests from =
blob_test.rb are "wrong".
Yet when I use for instance phpMyAdmin to store data without Ruby, I can =
later with Ruby retrieve characters 26 correctly.
So the problem seems to happen only when storing into the blob, not when =

Any solution ?


Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
trouble installing Ruby DBI for MySQL Jeff Anderson Ruby 4 11-17-2005 04:17 PM
DBI and DBI::Oracle packages configuration ulloa Perl 1 07-22-2004 05:52 PM
dbi:mysql mysql has gone away Paul Vudmaska Ruby 0 04-21-2004 06:19 PM
DBI problem : How can I load quickly one huge table with DBI ??. Tim Haynes Perl Misc 3 09-13-2003 03:43 AM
Mason, DBI, and DBI::Pg Asby Perl Misc 0 07-24-2003 09:04 PM