From: David De vits Date: 2008-02-05T18:51:35+09:00 Subject: mssql image field: ado returns an array Hi, Im trying to get an image out a mssql image type datafield thru DBI:ADO. The problem is that the result returned is an array and not a binary string and thus the image is garbage when i write it to a file. Is there a way to turn the array into a binary string ? Or some other solution ? this is the function i use to get the photo out of the database: def self.get_photo(dbh) sql = "SELECT p_photo, photoinfo, photo " + "FROM photos " + "WHERE p_photo = '0' " sth = dbh.prepare(sql) sth.execute() row = sth.fetch return row[2] end -- Posted via http://www.ruby-forum.com/.