CREATE OR REPLACE PROCEDURE public.update_budget_from_import()
	LANGUAGE plpgsql
AS $procedure$
begin 
truncate public.budgetdetails;

insert into public.budgetdetails (trxdescription, trxdate, trxamount)
select description, cast(dt as date) as dt_converted, amount 
from public.budgetimport;

end
$procedure$;
GRANT EXECUTE ON PROCEDURE public.update_budget_from_import() TO acedanger;
