workflow::state::fsm::pretty_name_unique_p (public)
workflow::state::fsm::pretty_name_unique_p -workflow_id workflow_id \ -pretty_name pretty_name [ -parent_action_id parent_action_id ] \ [ -state_id state_id ]
Defined in packages/workflow/tcl/state-procs.tcl
Check if suggested pretty_name is unique.
- Switches:
- -workflow_id (required)
- -pretty_name (required)
- -parent_action_id (optional)
- -state_id (optional)
- Returns:
- 1 if unique, 0 if not unique.
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: set exists_p [db_string name_exists { select count(*) from workflow_fsm_states where workflow_id = :workflow_id and pretty_name = :pretty_name and (:parent_action_id is null or parent_action_id = :parent_action_id) and (:state_id is null or state_id != :state_id) }] return [expr {!$exists_p}]XQL Not present: PostgreSQL, Oracle Generic XQL file: packages/workflow/tcl/state-procs.xql