Skip to Main Content

Warning 18.1

Warning: As of Apex 18.1, the solution below does not work anymore.

IR

EmpnoAscendingEnameJobMgrHiredateSalCommDeptno
7369SMITHCLERK79021980-12-17800-20
7499ALLENSALESMAN76981981-02-20160030030
7521WARDSALESMAN76981981-02-22125050030
7566JONESMANAGER78391981-04-022975-20
7654MARTINSALESMAN76981981-09-281250140030
  • 1 - 5 of 14

************************************************************

TIMING: 0.04 sec.
Shows the elapsed time in seconds used when rendering a region.

ROWS_FETCHED:
Shows the number of rows fetched by the Oracle Application Express reporting engine (the page size).

TOTAL_ROWS:
Displays the total number of rows that satisfy a SQL query used for a report.
Note: this is always 1 more than the actual number of rows. So when 0 rows are returned, TOTAL_ROWS is 1.

FIRST_ROW_FETCHED: 1
LAST_ROW_FETCHED:
Display the range of rows displayed.
For example: Row(s) 1 through of displayed

************************************************************

Info

Method to use the substitution strings from the Region Footer of (interactive) reports for other purposes.

In the example above, the #TOTAL_ROWS#; substitution string is used to fill page item P1009_REPORT_TOTAL_ROWS, using jquery.
The value of this page item can then be used in dynamic actions, e.g. to show/hide other items.
Note: Make sure that in your page template, the javascript substitution strings listed below are located in the Header and not in the Footer.
E.g. in Theme 42 of Apex 5.0 these are located in the footer, resulting in Javascript error "ReferenceError: $s is not defined".
#APEX_JAVASCRIPT#
#THEME_JAVASCRIPT#
#TEMPLATE_JAVASCRIPT#
#APPLICATION_JAVASCRIPT#
#PAGE_JAVASCRIPT# 
Item P1009_REPORT_ROWS_SHOWN contains the number of rows that are actually displayed in an Interactive Report; it is not useful for Classic Reports.
The number of rows displayed changes whenever e.g. using filters or changing the number of rows of the IR. Those types of IR actions have no effect on the substitution strings, since they refresh the report itself using PPR (Partial Page Refresh) and not the footer that contains the substitution strings.

Dynamic Actions

P1009_REPORT_ROWS_SHOWN (2x):
Note that we need 2 versions, because the class we are searching for got a new name in Apex 5.
Note also that you will probably need to substitute "LINK" for another column header, one that exist in your report and that cannot be hidden by the user.

To use P1009_REPORT_TOTAL_ROW, create true/false actions to show/hide items (or to perform any other actions you want).

Code

Page

Name
Page ID
Name

Region

Identification
Sequence
Title
Type
Source
Source Type
Region Source
Header And Footer
Region Footer

Item

Identification
Sequence
Name
Display As
User Interface
Region
Element
HTML Form Element Attributes

Item

Identification
Sequence
Name
Display As
User Interface
Region
Element
HTML Form Element Attributes

Dynamic Action

Identification
Name
Execution Options
Sequence
When
Event
Selection Type
Region
Server-Side Condition
Type
Expression 1
Advanced
Event Scope
True Action
Identification
Action
Settings
Code
Execution Options
Sequence
Fire On Initialization

Dynamic Action

Identification
Name
Execution Options
Sequence
When
Event
Selection Type
Region
Server-Side Condition
Type
Expression 1
Advanced
Event Scope
True Action
Identification
Action
Settings
Code
Execution Options
Sequence
Fire On Initialization

Dynamic Action

Identification
Name
Execution Options
Sequence
When
Event
Selection Type
Region
Advanced
Event Scope
True Action
Identification
Action
Settings
Code
Execution Options
Sequence
Fire On Initialization
Affected Elements
Selection Type
Item(s)