Hi,
Since a couple of days I get the follow error message when generating a branch:
Error: 'Cannot find either column "dbo" or the user-defined function or aggregate "dbo.tsf_user", or the name is ambiguous.'.
When compiling the function through the Functionality menu option, there are no problems, only when generating the branch. It would seem that the order of execution when generating functions has something to do with it, but the 2 functions used in this function, dbo.current_actor_id() and dbo.get_topic_access_level() both have a lower execution order number. So they should already exist before this function is generated. The function where the problem occurs is a new function, recently added.
Any ideas where I can look to see what the cause of the problem could be?
An unknown error occurred while executing '
/* Create or alter function can_assign_objective_topic_to_case. */
create or alter function "can_assign_objective_topic_to_case"
(
@process_id "identifier" ,
@objective_id "identifier" ,
@topic_id "identifier"
)
returns "no_yes"
as
begin
--control_proc_id: func_can_assign_objective_topic_to_case
--template_id: func_can_assign_objective_topic_to_case
--prog_object_item_id: func_can_assign_objective_topic_to_case
--template_description:
/*
Input
@process_id "identifier" ,
@objective_id "identifier" ,
@topic_id "identifier"
returns "no_yes"
*/
DECLARE
@v_actor_id identifier = dbo.current_actor_id();
IF dbo.get_topic_access_level(@objective_id, @topic_id) = 0
BEGIN
-- No access to the topic
RETURN 0;
END
IF EXISTS(SELECT 'x'
FROM active_process_view
WHERE process_id = @process_id
AND (archive_date IS NOT NULL
OR current_state_completed = 1
OR is_current_state = 0
OR actor_id <> @v_actor_id)
)
BEGIN
-- is not the actor of the current case state
RETURN 0;
END
IF NOT EXISTS(SELECT 'x'
FROM process_state_property psp
JOIN process_state pse ON pse.process_id = psp.process_id
AND pse.process_state_id = psp.process_state_id
AND pse.is_current_state = 1
WHERE psp.process_id = @process_id
AND psp.property_type = 17
AND psp.is_enabled = 1)
BEGIN
-- case has no editable TOPIC property in the current state
RETURN 0;
END
RETURN 1;
-- EOF
end
'.
Error: 'Cannot find either column "dbo" or the user-defined function or aggregate "dbo.tsf_user", or the name is ambiguous.'.

