I have a table with 2 dates begin_date and end_date. I have an Oracle APEX form that fetches data from this table. Is it possible on APEX side to calculate number of days between begin_date and end_date?
As far as I understand, I cannot create an item referring directly to an expression end_date-begin_date.
I tried to create two hidden items: P_BEGIN_DATE
referring to begin_date column and P_END_DATE
referring to end_date column.
And then create third item referring to an expression :P_END_DATE-:P_BEGIN_DATE
.
But this does not work because :P_BEGIN_DATE
and :P_END_DATE
appear to be strings, not dates.
Is there a way to calculate this difference without creating virtual column on database side?
P.S. I Use quite old version of APEX: 4.2.1. But if you know solution for newer version, please write it as well