Nonstop Database, HiRDB Version 9 UAP Development Guide
Normally, you would have to execute two SQL statements to obtain the total number of hits and the values of the rows that were hit. However, by using the facility for returning the total number of hits, you can combine the SQL statement for obtaining the total number of hits and the SQL statement for obtaining the values of the hit rows into a single SQL statement. As a result, the retrieval time for executing the two SQL statements essentially becomes the same as the retrieval time for executing one SQL statement.
To use the facility for returning the total number of hits, specify the COUNT(*) OVER()window function in a selection expression. For details about window functions, see the manual HiRDB Version 9 SQL Reference.
All Rights Reserved. Copyright (C) 2011, Hitachi, Ltd.