Code Listing 2: Implementing the allrows_cv function

 1  CREATE OR REPLACE PACKAGE BODY employee_level_qp
 2  IS
 3     FUNCTION allrows_cv
 4        RETURN employee_level_rc
 5     IS
 6        retval employee_level_rc;
 7     BEGIN
 8        OPEN retval
 9          FOR
10            SELECT   employer_id, employee_count, measurement_date
11                FROM employee_level
12            ORDER BY measurement_date;
13     
14        RETURN retval;
15     END allrows_cv;
16  END employee_level_qp;
17 /