Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3432332
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T07:26:10+00:00 2026-05-18T07:26:10+00:00

I have stored an image in a database using Blob type. Now I can

  • 0

I have stored an image in a database using Blob type. Now I can fetch this image from database using the select. I want to display this image on my jsp. In Jsp i have created a table and want it to be one of the column.

I have blob data how can I convert it back to an image and display it on my jsp page.

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T07:26:10+00:00Added an answer on May 18, 2026 at 7:26 am

    Here are two options:

    Option 1:

    This may not be the best answer, but it will do in a pinch…

    You would need to use a InputStreamReader to read the blob out of the column, and then create a FileOutputStream and then create the file in a ‘created’ images directory. For example if you store you image files in a directory called /pics, you could write the files out to a directory called /pics/generated.

    There are some drawbacks to this approach. For one you would generate a file every time the page is requested. which may work if the files will all have different names.

    Option 2:

    You would use an InputStreamReader to read the blob from the row that is returned from your SQL. Create an OutputStream, using a byte[] as the stream destination. Then it’s just a matter of writing the byte[] out to your JSP

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have stored my images in sqlite database.. i am reading the datas from
Image that I have a huge database which stores threads and posts from different
I have stored procedures in SQL Server T-SQL that are called from .NET within
I have stored procedure: ALTER PROCEDURE [dbo].[k_ShoppingCart_DELETE] @cartGUID nvarchar AS DELETE FROM [dbo].[k_ShoppingCart] WHERE
I have a stored procedure that consists of a single select query used to
I have months stored in SQL Server as 1,2,3,4,...12. I would like to display
I'm using a SQLite database to store cover images of books I have in
I have an xml in which i have stored some html under comments like
I have some template code that I would prefer to have stored in a
I have a strange, sporadic issue. I have stored procedure that returns back 5

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.