--
-- workflow__delete_arc/4
--
create or replace function workflow__delete_arc(
  character varying,
  character varying,
  character varying,
  character varying
) returns int4 as $$

declare
  delete_arc__workflow_key         alias for $1;  
  delete_arc__transition_key       alias for $2;  
  delete_arc__place_key            alias for $3;  
  delete_arc__direction            alias for $4;  
begin
        delete from wf_arcs
        where  workflow_key = delete_arc__workflow_key
        and    transition_key = delete_arc__transition_key
        and    place_key = delete_arc__place_key
        and    direction = delete_arc__direction;

        return 0; 
end;$$ language plpgsql;