I'd call it a bug/missing feature.
It appears that within a Basic report, sorting on a column created using APEX_ITEM.DATE_POPUP2() does not sort by date.
I'd file this with Oracle Support and see what they say.
Include a link to this thread and your workspace login information.
I got something to work by: (probably not what you want.)
- using the C004 column directly. (I just added it to the SQL code)
- setting the column's attribute "Display As" to "Date Picker"
- setting the column's attribute "Number /Date Format" to DD-MM-YYYY
I suspect: since you don't start with p_idx => 1, this column becomes "1" ==> g_f01
Thanks for looking at this!
The workaround you propose is something I had in place before using the date_popup2, but I have 2 reports on 1 page both with date fields in them: in both reports the date will get f01 as id and that gives a lot of issues processing the input.
I'll create a SR with Oracle Support and report back here when I get an answer.