I want to use dynamic action using date picker in APEX 5.0 such that upon selection of start_date
and end_date
the interactive report should display the data for the date range selected.
I first created an interactive report in APEX and then created a page items with date pickers. In my database table, I have a column name time_stamp
which is of datatype varchar2
with date format as YYYY-MM-DD-HH24:MI:SS
.
My query for interactive report looks like below:
Select * from table1 where time_stamp between to_char(to_date(:p1_item,'YYYY-MM-DD-HH24:MI:SS'),'DD-MM-YY') and to_char(to_date(:p2_item,'YYYY-MM-DD-HH24:MI:SS'),'DD-MM-YY')
( where p1_item
and p2_item
are the page items for date pickers), the "Format Mask" attribute for the date pickers I have set to DD-MM-YY
. Now I need to define a dynamic action to execute my interactive report SQL query based on the start_date
and end_date
selected. I need to further know the steps to create such a dynamic action and looking for the detailed steps for what attributes needs to set to achieve this.