Displaying image in an Interactive Report - oracle-apex

I am using APEX 21.1. I am building a clinic management system. I have an interactive report based on a join between two tables SELECT e.id examination_id,E.DIAGNOSIS,dbms_lob.getlength(a.img) img, a.id,attachment_id FROM examination e JOIN examination_attachment a ON A.EXAMINATION_ID = e.id. The examination could have many attachments. This is the result of the query.
I changed IMG column's type to Display Image. When it asks for BLOB ATTRIBUTES, I set table name to examination_attachment. That's the table that have the images. And I enter the primary key as the table's PK(id). The page displays error No data found. The SQL query returns that id duplicated when there is more than one row in the examination_attachment table. I think that's the reason behind the error but not sure. I created a view with the same select statement without the dbms_lob.... part. Just selected the IMG column. And in BLOB attributes, I set the table to the view name, and the primary key as the attachment_id because it's the column that's not duplicated. And it worked. But I need to get it to work without views and I need to know if the cause of the error is right?

Related

Oracle APEX 21.2.0 display image Primary Key

I want to display image in report column. My table has composite primary key: ID and DATE.
When I add these columns in BLOB attributes as Primary Key Column 1 and Primary Key Column 2 report can not find data because of DATE column. Is it a problem in date format, or something else?
I'd suggest you to use only one column as a primary key column (a sequence or - if your database version supports it - an identity column).
Combination of [ID, DATE] you currently have can then be set to unique key (set both columns NOT NULL to "mimic" what primary key would do).
Why? Although your data model probably is just fine, certain Apex functionalities "suffer" from such things and prefer having a single-column primary keys.

How to filter cards based on table data row selection in Power BI?

I am working on a report that deals in employee feedbacks. I have different cards on top to show -
(Requests Received,Type of requests(social/others/security),Requests reported/not reported and expired).
All these cards have data based on a measure - Count of Employee IDs = count('vw_EmployeeFeedback'[Employee_Id]) + 0 and respective filter fields dragged on to them to show category type etc.
Below them I have a table to show the detailed view of the data. Such as names of manager raising the request, Request raised for(name field) , status of requests, submitted date etc. coming from the same view as Count of Employee Ids.
I want the cards to filter based on the selection of a row in the table.
The edit interaction are set to filter the cards, but all go zero or blank when I select a row in the table.
Please let me know how I can achieve this. Thank You!
I am assuming that you have different tables for your data source/s that is why it is not filtering when clicking the table entry. Try establishing the relationships of your tables. Just go to Models and then Manage Relationships. If it's not the case, then you need other solutions.

How to write a query based on the Date item, in interactive grid

I have a date field and a interactive grid. I am trying to generate the Interactive grid based on the value inputted in the date field.
I am trying to write the query as below :
select pap.effective_start_date , pap.effective_end_date
from per_all_people_f pap
where :SELECT_DATE between pap.effective_start_date and
pap.effective_end_date
Here, SELECT_DATE is the name of the Date field (datatype Date picker). I am writing a dynamic action on Change of Date field, and refreshing the interactive grid region.
But when I change the value in Date field, it doesn't return any rows.
I have done a similar change where my interactive grid was based on a dropdown. There I had to set the "page action on selection" to Submit, and it worked. But here, since it is a Date field, the "Page Action on selection" property doesn't appear on the page .
Can somebody please suggest, how can I achieve this.
You need to explicitly convert your bind variables, which are treated as strings, to dates.
to_date(:SELECT_DATE)
The format mask will come from the application properties, or you can be explicit with that, too.

Formatting a portal in FileMaker 13 to show related text only and not keys

I am using FileMaker Pro 13. I need to add Portal to show data from related table.
Some fields which I wanna add to Portal are "Foreign keys" from that related table that are linked-related to third table.
Results I am getting in Portal from those fields are numbers, but I need data (text) from that third table that is related to that "Foreign key".
Is it possible to create portal that shows text related to that foreign key, and if it is, how to achieve that?
Thanks a lot!
Example schema is on link https://www.lucidchart.com/invitations/accept/e45dfdfd-185d-46c8-ad9e-e8e8dc270ee7
In general words, I want to add Portal on layout based on Table3, so I can view related data from Table2, and it would have fields tbl2item, TBL1_foreign key (from where I pull data from Table 1 when I enter data in Table 2, using pop up menu). And in Portal data I need TBL1_foreign key to be represented as text from related table instead of auto-numbers.
Assuming the relationship:
Table 1 --> Table 2 --> Table 3
You are in the layout based on Table 1. Make sure there is relationship to Table 3 and it is in the same group (TOG) in Manage Databases. Just place the field with text from the Table 3 on your portal row and it should work.
Make sure you select the correct relationship for Table 3. In drop-down list it should be in "Related" group. Should look like "Table 3::myFiled" on the layout, with the name the same as the name of your table instance (TO) from "Manage database" which could be different from your base table name
The other option would be to use value list.
I do not see your file, so if it does not work for you, post more details about your setup.

django-tables2: perform an action on click of a row

How to perform some desired action (like saving some values to a session variable that i can use for loading the next page) when a row is clicked in a table created using django-tables2
I am using to django-tables2 to display some data that is coming from DB
In other words I want my table rows to be clickable