FireRuby 0.4.1 and blob data


First, I would like to apologize if I am skipping any vital steps in my
ignorance. I am currently building a GTK application using Ruby, a small
data retrieval and storage thingie that deals basically with drag and
visual associations between data. A central part of it demands that I
retrieve an image from a Blob column in a Firebird database to feed a
The issue I’m having is this: using blob_data.to_s locks up Ruby, and
blob_data.each raises the following exception:

./lib/sign.rb:19:in `each’: Error reading blob segment.
segment buffer length shorter than expected
segment buffer length shorter than expected

I had tried a couple of weeks ago to import data into a blob column
FireRuby, and retrieving them later resulted in 0 byte images. The
made me rewrite what I had in Python, just to get the job done – which
regret, since it has delayed this question and made me write Python. Am
doing something fundamentally wrong, is there anything I seem to be
forgetting? I’m using FireRuby 0.4.1, Ruby 1.8.4 and Firebird 1.5, and
data is certainly there, I can get it back fine using other methods.

Thanks in advance for reading this. Any help is appreciated.

I don’t mean to bother, but… anyone?

Try the author, who can be found at

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs