Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Rails Problem - Ms Sqlserver image columns and Rails

Reply
Thread Tools

Rails Problem - Ms Sqlserver image columns and Rails

 
 
erhan
Guest
Posts: n/a
 
      06-30-2006
Hi,

We are suffering from SQLSErver image column problem...
We have a image column stored in SQL Server 2005 and
We used the technique told in "Agile Web Dev with Rails" to display it
in a web browser...


But, all we get is numbers... And img tag can not display it...


Could you know a workaround for this problem, and if it is so, could
you share it with us... Is this specific to Ms SqlServer?


Here is controller action sending image data...
def GetPict
@p = Personel.find("5049-0361")
send_data @p.Pict,
:filename => "pict.bmp", :type =>
"image/bmp",
:disposition => "inline"
End


And here is corresponding rhtml part....
<tr><td>
<img src = "<%= url_for(:action => "GetPict") %>" />
</td></tr>


Thanks in advance....

 
Reply With Quote
 
 
 
Reply

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
Upgrading ASP w/SQLserver 2000 to ASP.NET w/ SQLserver 2005 =?Utf-8?B?SmVmZnJleQ==?= ASP .Net 2 04-27-2007 03:33 PM
database columns vs. gui columns and sorting ittay.dror@gmail.com Java 5 03-04-2006 10:48 AM
CSS columns problem - faux columns don't work henrybranson@hotmail.com HTML 4 11-24-2005 10:05 AM
convert rows to columns and columns to rows helpful sql ASP .Net 0 05-19-2005 06:03 PM
sessionstate sqlserver mode image path problem Phl ASP .Net 0 12-02-2004 06:09 PM



Advertisments