Hi! How to display image from table in card report. I created card report, but when I add blob file into sql query I get [datatype] instead of image. I tried to find solution, but I couldn’t. Thanks in advance!
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
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.
In Oracle Apex, take the BLOB column as length using the dbms_lob.getlength() function instead of directly picking the column for your report query. For example:
Now set the report column PRODUCT_IMAGE properties as shown in the below image: The primary key column must be set.
Instead of PRODUCT_IMAGE column name, maybe you have to set alias as CARD_TEXT or CARD_SUBTEXT. That you can check.
Also, If you have the filename, mime type columns in your table, then you should specify it in the above settings, but they are optional.
Let me know if still any issues.
Thank you for response Vinish! Now, I get image like in screenshot below.
The method I suggested above is tested and works fine.
Can you show me your query? Or tell me what alias you defined for the image column?
I use different table, but query is similar like Your, I use “CARD_TITILE” for image column .
Your SQL query seems ok, perhaps you should check if the BLOB data in the column is not empty.
You can run this query into SQL developer or in any other tool to check if the length of the BLOB column is greater than 0.
By looking at your image, it seems, that the BLOB data is not an image file, it is PDF or something, you have to confirm the BLOB data content by opening in any tools like Toad or SQL Developer.
Also, check if you defined the BLOB attributes correctly as I shared in the above image.
For the image quality, maybe you didn’t define the size of the image that is why.
I have also changed my query for CARD_TITLE and it shows the data image correctly.
Sorry for late answer.
You are right, when I try with demo table it works.
This application is on apex.oracle.com, and I think that I can’t use SQL Developer for this app. Correct me if I am wrong.
can I update table column with blob datatype through – SQL Workshop/SQL Commands on apex.oracle.com? I tried but it seems that column is empty.
If apex.oracle.com hosting is paid, then you can access it using any other database tools by using the database credentials.
But you can do one thing, create a temporary report and dialog form through the wizard for the table you want to update or add new blob data.
Through wizard it will create blob item as file browse in the dialog form, there you would be able to upload new images easily.
hello am, also having related issue
my page displays no data
here is my query
select
PROP_LOCATION_NM CARD_TEXT,
PROP_LOCATION_CD CARD_SUBTITLE,
PROP_LOCATION_REGION CARD_SUBTEXT,
decode(nvl(dbms_lob.getlength(PROP_LOCATION_IMAGE),0),0,null,’‘) “CARD_TITLE”
from WADOMASS_PROP_ADRESS;
can anyone assist please
First, run your query separately and check if it is returning records. If returning, then it should show in the card report. To test, you can remove the blob column for now and check with the following columns only:
If the report shows the data, then it means somewhere problem with your blob data.