# FireRuby 0.4.1 and blob data

**URL:** <https://www.ruby-forum.com/t/fireruby-0-4-1-and-blob-data/101696>\
**Category:** Ruby\
**Created:** [August 7, 2006, 3:06pm UTC](https://www.ruby-forum.com/t/fireruby-0-4-1-and-blob-data/101696 "2006-08-07T15:06:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vitor\_P](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/b5ac83/32.png) [@Vitor\_P](https://www.ruby-forum.com/u/Vitor_P)\
**Post date:** [August 7, 2006, 3:06pm UTC](https://www.ruby-forum.com/t/fireruby-0-4-1-and-blob-data/101696/1 "2006-08-07T15:06:29Z")

</div>

Hello,

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  
drop,  
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  
GtkImage.  
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.  
(FireRuby::FireRubyException)  
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  
using  
FireRuby, and retrieving them later resulted in 0 byte images. The  
failure  
made me rewrite what I had in Python, just to get the job done – which  
I  
regret, since it has delayed this question and made me write Python. Am  
I  
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  
the  
data is certainly there, I can get it back fine using other methods.

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

---

<div class="post-metadata">

**Author:** ![Vitor\_P](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/b5ac83/32.png) [@Vitor\_P](https://www.ruby-forum.com/u/Vitor_P)\
**Post date:** [August 8, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/fireruby-0-4-1-and-blob-data/101696/2 "2006-08-08T19:06:21Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![Vitor\_P](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/b5ac83/32.png) [@Vitor\_P](https://www.ruby-forum.com/u/Vitor_P)\
**Post date:** [August 8, 2006, 8:31pm UTC](https://www.ruby-forum.com/t/fireruby-0-4-1-and-blob-data/101696/3 "2006-08-08T20:31:04Z")

</div>

Try the author, who can be found at  
[http://rubyforge.org/projects/fireruby/](http://rubyforge.org/projects/fireruby/)
