select *
from rpt.hosp_pneumonia_list_pg(
cast($1 as int8), 
$2, 
cast($3 as int8), 
cast($4 as int8), 
cast($5 as int8), 
cast(to_timestamp($6,'dd.mm.yyyy') as timestamp),  
cast($7 as time))
