Q:

Add blank rows between a group of mutliple rows - Oracle

Is there a possibility to add blank rows in a group of data rows dynamically ? I have the below query which fetches data in multiple rows. I want to separate, say add blank row after each 5 rows.
The query : 
select php.ref_dcp_key, sum(php.group_booking), count(php.group_booking), 0 
from gx_pnr_history ph, gx_pnr_his_prof php
where ph.gmpnr_loc_key = php.gmpnr_loc_key
group by php.ref_dcp_key order by php.ref_dcp_key;

A:

@SandeepGowada, you'd have to create an outer structure for the rows and put in the 6th padding row after every 5 data rows.
I second the view of @juergend that this should really be done in the presentation layer (although often it probably requires no less code overall to do it there than in SQL - but it does frustrate the workings of anything other than a static report, like datagrids that allow re-sorting or filtering)
I've knocked together some untested code (using Oracle syntax) which shows an example of how it's done - how we prepare the base data, then build a table of placeholders for all necessary rows, then join the base data onto the placeholders in the appropriate places. I've made some of the calculations a bit more elaborate to show where the number 5 constant is being used.
Also, I haven't included any code to knock off any surplus padding rows in the final group (i.e. as it stands the number of rows returned will always be a multiple of 6, regardless of the underlying data).
Nor have I included any code regarding the required numbers_table or sequence generator.
WITH base_data AS
(
    SELECT 
        php.ref_dcp_key
        ,sum(php.group_booking)     AS group_booking_sum
        ,count(php.group_booking)   AS group_booking_count
        ,0                          AS zero_value_column

        ,MOD(ROW_NUMBER() OVER (ORDER BY php.ref_dcp_key) - 1, 5)           AS group_line_num
        ,(  (ROW_NUMBER() OVER (ORDER BY php.ref_dcp_key) + (5 - 1)) / 5  )     AS row_group_num

        --all appearances of the number 5 constants determine the number of lines per group

    FROM
        gx_pnr_history /*AS*/ ph

    INNER JOIN
        gx_pnr_his_prof /*AS*/ php
        ON (ph.gmpnr_loc_key = php.gmpnr_loc_key)

    GROUP BY 
        php.ref_dcp_key 
)

,row_structure AS
(
    SELECT
        MOD(number - 1, (5 + 1))            AS group_line_num
        ,number + ((5 + 1) - 1) / (5 + 1)   AS row_group_num

    FROM
        number_table /*this needs to be a reference either to a numbers table, or a number sequence generator*/

    WHERE
        number BETWEEN 1 AND ((SELECT MAX(row_group_num) * (5 + 1) FROM base_data))
)

SELECT
    ref_dcp_key
    ,group_booking_sum
    ,group_booking_count
    ,zero_value_column
    ,ROW_NUMBER() OVER (ORDER BY row_structure.row_group_num ASC, row_structure.group_line_num ASC) AS final_order

FROM 
    row_structure

LEFT JOIN
    base_data
    ON (base_data.row_group_nun = row_structure.row_group_num)
    AND (base_data.group_line_num = row_structure.group_line_num)

ORDER BY 
    final_order

