• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Displaying image from dbase

 
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


Hi
Buddies can any one help me out to displaying
the image stored in dbase

 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would start by looking at what java.sql.ResultSet returns
http://java.sun.com/j2se/1.4.2/docs/api/java/sql/ResultSet.html

GetBinaryStream should do it. There is also getBlob.
Then I would learn how to stream binary data to a browser.

I have an example of a servlet that streams images from file that you should be able to rework pretty easily.
http://simple.souther.us
Get SimpleStream and look at the source files in there.

Lastly, don't try to do this from a JSP.
Do it from a servlet.
 
reply
    Bookmark Topic Watch Topic
  • New Topic