I have a function called generate_table, that takes 2 input parameters (rundate::date and branch::varchar)
rundate::date
branch::varchar
Now I am trying to work on a second
No need to do anything too fancy.
SELECT generate_table(rundate,branch) FROM ( SELECT max(rundate) AS rundate, branch FROM t_index_of_imported_files GROUP BY branch) x;