# Fleximage: hsowing image from db, need help

**URL:** <https://www.ruby-forum.com/t/fleximage-hsowing-image-from-db-need-help/149370>\
**Category:** Rails\
**Created:** [September 24, 2008, 9:29am UTC](https://www.ruby-forum.com/t/fleximage-hsowing-image-from-db-need-help/149370 "2008-09-24T09:29:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![maep](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/90ced4/32.png) [@maep](https://www.ruby-forum.com/u/maep)\
**Post date:** [September 24, 2008, 9:29am UTC](https://www.ruby-forum.com/t/fleximage-hsowing-image-from-db-need-help/149370/1 "2008-09-24T09:29:04Z")

</div>

Hi!  
For a few days I am struggling with Fleximage.  
Current problem is:  
I want to show image, loaded in database. I want, but I cant.

In account model (acts\_as\_fleximage) there is a field image\_file\_data,  
images are stored there. (Images are good, I can see them with MySQL  
Query Builder)

I want to show picture in edit view.  
What is done:

In account\_controller there is a method:

def image  
@account = Account.find(params[:id])  
render\_flex\_image(@account)  
end

in account/edit view:

\<%= image\_tag url\_for(:action =\> ‘image’, :id =\> @account) %\>

In html we have: (2 is id, it’s right id:))

![2](https://www.ruby-forum.com/accounts/image/2)

But, in place i expect to see picture, i see number “2” in square.

What am I doing wrong, or missing?  
One bad thing: if in “image” method i use @account.has\_image?,  
in web server log i see that error:

script/server: No such file or directory - cl -nologo -LD -MD -Zi  
-O2b2xg- -G6 -I c:/ruby/lib/ruby/1.8/i386-mswin32 -I c:/ruby/include  
-Lc:/ruby/lib -o “C:\Documents and  
Settings\USER/.ruby\_inline/Inline\_ImageScience\_aa58.so” “C:/Documents  
and Settings/USER/.ruby\_inline/Inline\_ImageScience\_aa58.c” -lfreeimage  
-lstdc++ -link /LIBPATH:“c:/ruby/lib” /DEFAULTLIB:“msvcrt-ruby18.lib”  
/INCREMENTAL:no /EXPORT:Init\_Inline\_ImageScience\_aa58

Thank you for your answers!
