How do I display blob (image) in a Portal Report

I am using 9ias 10222 and portal 30983 and I have a table that stores an image as a blob and have a varchar field to store the mime type. I have created a form to upload the image and can then query the form to display the image.
How do I dislay the image in a Portal Report/Dynamic Page Component. I have followed note 68016.1 but the retrieve_img_data procedure does not work it gives a wwv-11230 error.
Any ideas? Any help would be appreciated.
Thanks
Belinda

Hi,
Can you display what code you used for this? I followed note 172045.1 and everything compiles properly but when I run the report, I just get a box with a red X in it, like it is not finding the picture. I ran the procedure that downloads the image and it works fine from there. Thanks.

Similar Messages

  • Display BLOB (image) column in (interactive) report

    Hi,
    I have a field called "picture" in my table "details" which is of type BLOB. i also have a field for "MIMETYPE" and "filename"
    i additionally have a "name" and "description" columns which i need to display along with the picture as columns in a report (preferably interactive).
    i have also modified the BLOB display format as per
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/apex/r31/apex31nf/apex31blob.htm
    what i am missing is the correct query. if possible, i would like to control the size of the picture rendered within the report like say 40*50.
    I have also referred to the thread
    APEX 3.1 Display BLOB Image
    But i don't know how to place the
    dbms_lob.getlength("BLOB_CONTENT") as "BLOB_CONTENT"
    in my query.
    The above also makes the report column as of type "number". is this expected?
    Any help would be much appreciated.
    Regards,
    Ramakrishnan

    You haven't actually said what the problem is?
    >
    I have a field called "picture" in my table "details" which is of type BLOB. i also have a field for "MIMETYPE" and "filename"
    i additionally have a "name" and "description" columns which i need to display along with the picture as columns in a report (preferably interactive).
    i have also modified the BLOB display format as per
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/apex/r31/apex31nf/apex31blob.htm
    what i am missing is the correct query.
    I have also referred to the thread
    APEX 3.1 Display BLOB Image
    But i don't know how to place the
    dbms_lob.getlength("BLOB_CONTENT") as "BLOB_CONTENT"
    >
    Something like:
    select
              name
            , description
            , dbms_lob.getlength(picture) picture
    from
              details
    if possible, i would like to control the size of the picture rendered within the report like say 40*50.For images close to this size it's easy to do this for declarative BLOB images in interactive reports using CSS. Add a style sheet with:
    .apexir_WORKSHEET_DATA td[headers="PICTURE"] img {
      display: block;
      width: 40px;
      border: 1px solid #999;
      padding: 4px;
      background: #f6f6f6;
    }where the <tt>PICTURE</tt> value in the attribute selector is the table header ID of the image column. Setting only one dimension (in this case the width) scales the image with the correct aspect ratio. (The border, padding and background properties are just eye candy...)
    However, scaling large images in the browser this way is a huge waste of bandwidth and produces poorer quality images than creating proper scaled down versions using image tools. For improved performance and image quality, and where you require image-specific scaling you can use the database ORDImage object to produce thumbnail and preview versions automatically, as described in this blog post.

  • How to print a BLOB (image) on a PDF report using Oracle APEX Listener as Print Server

    Hi,
    I use APEX 4.2.
    I have the following query as SQL text for a Report Queries in Shared Components:
    select
        customer_id,
        cust_first_name,
        cust_last_name,
        cust_street_address1,
        cust_street_address2,
        cust_city,
        cust_state,
        cust_postal_code,
        phone_number1,
        phone_number2,
        credit_limit,
        cust_email,
        filename,
        company_profile,
        -- customer_image,
        decode(nvl(dbms_lob.getlength(customer_image),0),0,null,
        '<img style="border: 4px solid #CCC; -moz-border-radius: 4px; -webkit-border-radius: 4px;" '||
        'src="' ||
        apex_util.get_blob_file_src('P22_CUSTOMER_IMAGE', customer_id) ||
        '" height="75" width="75" alt="Photo Customer" title="Photo Customer" />') customer_image,
        mimetype,
        image_last_update
    from
        demo_customers;
    I am unable to have the image printed on the PDF report. Even when the P22_CUSTOMER_IMAGE is defined as session state item.
    Does someone knows how to print such image/BLOB in a PDF report?
    Thanks by advance.
    Kind Regards.

    Hi,
    Indeed, I would need a custom layout.
    Unfortunately, it seems (according to this white paper) not possible with the APEX listener only. I would need a third pary tool. A pity...
    For me strange, that I cannot generate such a report having images or pictures in a pre-definied report layout... Maybe a future enahancement for Oracle.
    Kind Regards.

  • I want to display BLOB image in JSP Using  html tags IMG src=

    GoodAfternoon Sir/Madom
    I Have got the image from oracle database but want to display BLOB image using <IMG src="" > Html tags in JSP page . If it is possible than please give some ideas or
    Send me sample codes for display image.
    This code is ok and working no problem here Please send me code How to display using html tag from oracle in JSP page.
    <%@ page import="java.sql.*" %>
    <%@ page import="java.io.*" %>
    <%@ page import="javax.swing.ImageIcon;" %>
          <%
            out.print("hiiiiiii") ;
                // declare a connection by using Connection interface
                Connection connection = null;
                /* Create string of connection url within specified format with machine
                   name, port number and database name. Here machine name id localhost
                   and database name is student. */
                String connectionURL = "jdbc:oracle:thin:@localhost:1521:orcl";
                /*declare a resultSet that works as a table resulted by execute a specified
                   sql query. */
                ResultSet rs = null;
                // Declare statement.
                PreparedStatement psmnt = null;
                  // declare InputStream object to store binary stream of given image.
                   InputStream sImage;
                try {
                    // Load JDBC driver "com.mysql.jdbc.Driver"
                    Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
                        /* Create a connection by using getConnection() method that takes
                        parameters of string type connection url, user name and password to
                        connect to database. */
                    connection = DriverManager.getConnection(connectionURL, "scott", "root");
                        /* prepareStatement() is used for create statement object that is
                    used for sending sql statements to the specified database. */
                    psmnt = connection.prepareStatement("SELECT image FROM img WHERE id = ?");
                    psmnt.setString(1, "10");
                    rs = psmnt.executeQuery();
                    if(rs.next()) {
                          byte[] bytearray = new byte[1048576];
                          int size=0;
                          sImage = rs.getBinaryStream(1);
                        //response.reset();
                          response.setContentType("image/jpeg");
                          while((size=sImage.read(bytearray))!= -1 ){
                response.getOutputStream().write(bytearray,0,size);
                catch(Exception ex){
                        out.println("error :"+ex);
               finally {
                    // close all the connections.
                    rs.close();
                    psmnt.close();
                    connection.close();
         %>
         Thanks

    I have done exactly that in one of my applications.
    I have extracted the image from the database as a byte array, and displayed it using a servlet.
    Here is the method in the servlet which does the displaying:
    (since I'm writing one byte at a time, it's probably not terribly efficient but it works)
         private void sendImage(byte[] bytes, HttpServletRequest request, HttpServletResponse response) throws IOException {
              ServletOutputStream sout = response.getOutputStream();
              for(int n = 0; n < bytes.length; n++) {
                   sout.write(bytes[n]);
              sout.flush();
              sout.close();
         }Then in my JSP, I use this:
    <img src="/path-to-servlet/image.jpg"/>
    The name of the image to display is in the URL as well as the path to the servlet. The servlet will therefore need to extract the image name from the url and call the database.

  • Displaying BLOB image by using ADF Faces

    Hi all,
    I digged the forum but couldn't find any satisfied answer about displaying BLOB images by using ADF Faces.
    I have insterted POJO object to Oracle database but couldn't find any way to display blob (in java byte [] ) data in POJO.
    I have read the POJO object from database which contains two field; one of them is id field and other is BLOB data which holds GIF or JPG image and I want to display this image another page which contains also other fields / records ...
    thanks for your answers
    regards...
    --baris                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    This thread at Sun : http://forum.java.sun.com/thread.jspa?threadID=513804&messageID=2445090
    talks about two options for creating a graphicImage jsf tag. (img tag)
    1. Make the img tag url refer to a servlet (instead of a static image file)
    2. Embed the image into the tag as inline base64 encoded data.
    2a. Use an <Object> tag with inline data.
    1. Looks a bit complex for a simple problem.
    2 and 2a don't work with some browsers.
    - And I've not yet figured out how to hook into the ADF Faces table-rendering logic to get it to add my image column. My table binds to a collection DataControl, [which in turn retrieves from a findAllItems call on a session facade, which uses my domain model, and wraps up access to a TopLink pesistence layer]. The framework just ignores my byte[] attribute when creating the jsf table from the DataControl. All string, int etc. attributes get represented correctly in the jsf table output.

  • Displaying blob image using adf

    Hi ,
    We are using adf in our application. We have to disaply blob image from oracle data base on the adf jspx page.This jspx page consists of 2 jsff files.
    I have created an httpservlet and called on the source parameter of image this httpservlet with binding similar as below:
    source="/httpServletName?id=#{bindings}}"
    I am able to display the image.
    But my concern is that I am using iterator for displaying images as there can be multiple records in the table but for every recoed I am getting same image. Please suggest how can I display multiple images coming with respect to various records of data base.
    thanks & Regards

    Hi,
    After attempting the solution given above also I am getting the same issue.
    On the jspx page I want to show Imageid, imagedescription and photo .
    I have 4 records coming from database on the jspx page. I have found that all the data (imageid, description) is first displayed on the jspx and then control gets transferred on the ImageServlet only once and in request.getParameterMap() I get only one "ID" value i.e. the ID value of last record (4th record) coming from data base and hence in all the 4 records on jspx I am getting the same image (i.e. the image in the 4th record of db). Please help me to proceed on this issue.
    On jspx, I have given image source value as :
    <af:image shortDesc="image"
    id="image1"
    source="/imageservlet?id=#{bindings.Id.inputValue}}"/>
    Thanks

  • Problem with displaying BLOB images on JSP page using a servlet

    hi. I have a big problem with displaying BLOB images using JSP. I have a servlet that connects to the oracle database, gets a BLOB image , reads it, and then displays it using a BinaryStream. The problem is , this works only when i directly call that servlet, that is http://localhost:8080/ImageServlet. It doesn't work when i try to use that servlet to display my image on my JSP page (my JSP page displays only a broken-image icon ) I tried several coding approaches with my servlet (used both Blob and BLOB objects), and they work just fine as long as i display images explicitly using only the servlet.
    Here's what i use : ORACLE 10g XE , Eclipse 3.1.2, Tomcat 5.5.16 , JDK 1.5
    here is one of my image servlet's working versions (the essential part of it) :
                   BLOB blob=null;
              rset=st.executeQuery("SELECT * FROM IMAGES WHERE ID=1");
              while (rset.next())
                   blob=((OracleResultSet)rset).getBLOB(2);
              response.reset();
              response.setContentType("image/jpeg");
              response.addHeader("Content-Disposition","filename=42.jpeg");
                    ServletOutputStream ostr=response.getOutputStream();
                   InputStream istr=blob.getBinaryStream(1L);
                    int size=blob.getBufferSize();
              int len=-1;
                    byte[] buff = new byte[size];
                         while ((len=istr.read( buff ))!=-1 ) {
                   ostr.write(buff,0,len);
             response.flushBuffer();
             ostr.close(); and my JSP page code :
    <img src="/ImageServlet" border="0"  > If you could just tell me what i'm doing wrong here , or if you could show me your own solutions to that problem , i would be very greatful ,cos i'm realy stuck here , and i'm rather pressed for time too. Hope someone can help.

    I turns out that it wasn't that big of a problem after all. All i had to do was to take the above code and place it into another JSP page instead of into a servlet like i did before. Then i just used that page as a source for my IMG tag in my first JSP. It works perfectly well. Why this doesn't work for servlets i still don't know, but it's not a problem form me anymore . Ofcourse if someone knows the answer , go ahead and write. I would still appriceatte it.
    here's the magic tag : <img src="ImageJSP.jsp" border="0"  > enjoy : )

  • How can i display a image file which is placed in the applications server

    Hi all,
    Can any one help me how can I display a image file which is present in the application server.
    With regards,
    M.Ramana Murthy

    hi,
    *& Form TOP_OF_PAGE
    * text
    FORM F_TOP_OF_PAGE.
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
    IT_LIST_COMMENTARY = IT_LISTHEADER
    i_logo = Logo name
    * I_END_OF_LIST_GRID =
    ENDFORM. "TOP_OF_PAGE
    rgds
    Anver

  • Image display - How do I display an image using an absolute path?

    How do I display an image using an absolute path in a compiled WebHelp?
    Our developers use RH8 map IDs within our in-house applications to display in a model window created using Telerik Rad Window.
    Unfortunately images disappear from these model windows because RoboHelp removes absolute links to [inserted] images and changes them to relative in the compiled WebHelp.
    How do we overcome this? Is there a solution in RH8?

    I have tried again and changed the path in the topic HTML
    from : ..\..\HelpTopics\Icon_Search.png
    to    :  \HowDoI\Help_CMS\WebHelp\HelpTopics\Icon_Search.png
    I am obviously unable to see it in RH8 as I have removed the relative link so it is "outside" of the project.
    This time, on compilation, it has not stripped out the absolute links. The developer was working with me on this last week and we did have any issue in that they did not hold the absolute link. Most odd!
    Checking the published help it appears to be working in the application, which is great.
    So my apologies for raising the issue but it really did not work last week.

  • How can i set an image to a portal

    how can i set an image to a portal using response.write();
    please guide me i have an image in C drive how to get the image

    Hello,
    you can use the HTML Tag:
    <img src="file://c:/path/image.jpg" />
    Regards
    Gregor

  • How to display a BLOB (Image) in a EBS Report?

    User requested to add a Logo image to a report which is called from E-Business Suite (EBS).
    The image is currently stores in a BLOB column.
    How can I make the image to display on the report?
    Thanks!

    I was trying to use the BLOB and display the image in a report.
    Per your suggestion:
    "Select the column in your query.
    Create an item in the layout editor and set the source to this column.
    Set File Format to Image."
    My question was I dont know how to "set the source to this column" as you described above.
    So, to work around it, I moved the image file phyically to the UNIX file system.
    Then, created an item in the layout editor which required a valid "image file path" the property palette.
    Since, the report was created under windows, it did not validate with UNIX file path.
    That's why i need to perform extra steps to get the file path correct to work in UNIX.
    EDIT:
    I guess when you said "set the source to this column", you mean to map the "Field source" attribute in the property palette to the database column from query.
    But depends on what item you want me to create (I created a "Link File" item) and it does not have the "Field source" attribute available to map to a database column.
    Edited by: user595907 on Sep 21, 2009 9:47 AM
    Edited by: user595907 on Sep 21, 2009 9:54 AM

  • Displaying BLOB image in an item

    I have a table with a BLOB column holding an image.
    I can set up a report region with a query on the column like this (the whole sql query is omitted for simplicity, I am just showing relevant column):
    dbms_lob.getlength(a.product_logo)
    and then put a mask on the report column:
    IMAGE:PROJECT:PRODUCT_LOGO:PROJECT_ID::::::inline:Download
    and it works. The report region, when ithe page runs, displays the image.
    My problem is this...
    I am trying to set up a page where I already have an html region serving other purposes. I want to set up an item under that region that would display my image. I create an item of "Display As Text" type.
    I then enter my magic query dbms_lob.getlength(a.product_logo) into the item's "Source value or expression" field, while I set the "Source type" to "SQL Query". In the format mask for the item, I enter the same mask I showed above - "IMAGE:PROJECT:PRODUCT_LOGO:PROJECT_ID::::::inline:Download".
    I run the page and it doesn't work. The item comes back with a number. I am guessing it's the actual getlength value. What else am I missing? Or is it even possible to display an image BLOB through an item and not a report column?
    Thanks
    Boris

    Hi,
    Install demonstrative application and check page 6
    To install demonstrative app go
    Home>Application Builder>Create
    and select Demonstration Application
    Br,Jari

  • Display BLOB Image in a JSP page.

    Hi, Is there any easy way to display a Image in the browser using a JSP and an Oracle BLOB. I would like any code examples that anyone can provide me. I would like as many ways to do this as possible.
    Thanks Brian

    You can do it in 2 ways:
    1. Get the BLOB from the DB and then write it into the local harddisk where the Web Server is located and then give the path in the <IMG SRC> Tag.
    2. In the JSP, when you specify a IMG Tag
    <IMG SRC='FileDisplayServlet?hdImgName=new.gif'>
    This SRC is pointing to a Servlet. The Servlet will read the Query String and then go hit the DB, get the BLOB Content and then convert into a byte array. Now the servlet will change its content type to image or gif. Then it will write the content in the out stream.
    Hope this helps.
    Thanks and regards,
    Pazhanikanthan. P

  • How can I display an image from a shared-network folder?

    Hi
    Does anyone know how I can display images from within APEX that are found outside the database? What configuration have I missed?
    Within Windows-Internet-Explore I can access the following image using the below URLs, BUT I cannot access it from within APEX?
    What do I need to do so APEX can display theses images from our internal shared network folder?
    both these URLs work within Firefox (but on APEX):
    \\Saremote\UPDOWNFILES_DIR\polk_insight.gif
    file://///Saremote/UPDOWNFILES_DIR/polk_insight.GIF
    So within APEX I have created a "display as Text' Item that works with this "amazon image" syntax:
    {lessthan} IMG SRC= {doublequot} http://g-images.amazon.com/images/G/01/associates/navbar2000/logo-no-border(1).gif {doublequot} {greaterthan}
    BUT sadly not with my image:
    {lessthan} IMG SRC= {doublequot} file://///Saremote/UPDOWNFILES_DIR/polk_insight.GIF {doublequot} {greaterthan}
    Any ideas would be appreciated.
    Thanks
    Steve
    Edited by: [email protected] on Sep 12, 2008 8:30 AM
    Edited by: [email protected] on Sep 12, 2008 8:31 AM
    Edited by: [email protected] on Sep 12, 2008 8:32 AM
    Edited by: [email protected] on Sep 12, 2008 8:33 AM

    If you have a local html file, or open an image locally from the menu, then yes, it works, but with web pages that are served from a remote location (web server), security kicks in and prevents the web page from accessing local files (and files on a networked drive).
    you will either have to put the image on the web server and access it through http, or you can load it into the database/workspace images and access it that way.

  • Display Blob image in oracle forms

    i have an application in which i have to store all the employee's photos.
    i created the Photo column in database with datatype Blob.
    I created the form to store image that successfully stores image in database.
    bUt now what should i Do to display that image on Image Item when i execute_query.
    I m using Oracle forms 6i version & oracle 10 g database

    my image item contains all default properties set that are done when i create a database block PHOTO.
    i didnt set any property.
    Edited by: rupearlkaushal on Jun 8, 2012 6:33 AM

Maybe you are looking for

  • What is the best approach to handle multiple FK with single table.

    If two tables are joined with each other with more than one ways, for example MAIN table is (col1, col2,....coln, person_creator_id, person_modifier_id) PERSON table is (person_id, name, address,........ phone) etc At database level PERSON_CREATOR_FK

  • Software Restriction Policies in Win7

    Hi ,I have a problem with this Error message: This program is blocked by group policy,for more... How can I remove these restrictions? if you want any more data tell me to upload it,please Best Regards;

  • Multi level navigation menus in iweb

    Hi iweb experts I am creating a website that has multi levels. Basically a main page that links to 2 other main pages one for each of my kids and would like to have the navigation menus reflect that fact in iweb. So on the main page should have only

  • IP Address & Port Number

    We have some users who are unable to sign in when they want to use Folio Builder.  We suspect that the issue is down to our firewall as all standard ports are blocked.  I therefore need to know the IP Address and Port number that Folio Builder tries

  • Synchronous webservice-Acknowledgement

    Hi Experts, I have a scenario where I need to communicate between a synchronous webservice and an Idoc(async). Webservice Interface:(Sync) Sender Message: Webservice Response Reciever Message: Acknowledgement Reciever Interface:(Async) IDOC: ACC_DOCU