OBIEE 12c - How to use a column value as an image caption — Oracle Analytics

Oracle Analytics Cloud and Server

Welcome to the Oracle Analytics Community: Please complete your User Profile and upload your Profile Picture

OBIEE 12c - How to use a column value as an image caption

Received Response
12
Views
3
Comments
Mark.Thompson
Mark.Thompson Rank 6 - Analytics Lead

I am displaying an image in a pivot table, using this code:

<body>

<div class="thumbnail">

<figure>

  <img src="@H" "width=250px" border="0" />

  <figcaption>Caption goes here</figcaption>

</figure>

<span>

  <img src="@H" "width=800px;"/>

</span>

</div>

</body>

The words Caption goes here are currently displaying below the image.

Is it possible to replace the words Caption goes here with a reference to a column in the analysis, so that each image has a caption that is related to that image?

Answers

  • asim cholas
    asim cholas Rank 6 - Analytics Lead

    You can include the image inside a column in analysis itself in the column properties ->Style

  • I assume that piece of code is the custom code format of the column or something like that as you have the "@H" reference inside which is generally used to represent the URL being the value of the column.

    You can do what you look for, but you will need to move all that code inside the formula of the column, so you will be concatenating pieces of code together with values of columns, which allow you to reference the value of a column for the URL of the image and another column for the caption. And you then set the column format simply to HTML.

    Btw, the code is kind of bad from a HTML point of view, you can definitely make it cleaner and simpler (get rid of <body> etc.)

  • Mark.Thompson
    Mark.Thompson Rank 6 - Analytics Lead

    Thanks, Gianni.  I put the code into the column formula as a concatenated string.  Works great.

    Thanks also for the HTML tip.  I'm completely unqualified to write HTML, so I mostly do the OBIEE stuff, get the HTML working well enough to get by, and hand it off to someone more knowledgeable about HTML (who rolls his eyes and cleans it up).