UFN_BATCHTEMPLATE_ALLOWCOMMITININITIALSTATE
Return
Return Type |
---|
bit |
Parameters
Parameter | Parameter Type | Mode | Description |
---|---|---|---|
@BATCHTEMPLATEID | uniqueidentifier | IN |
Definition
Copy
create function dbo.UFN_BATCHTEMPLATE_ALLOWCOMMITININITIALSTATE(@BATCHTEMPLATEID uniqueidentifier)
returns bit
as begin
declare @ALLOWCOMMIT bit
select @ALLOWCOMMIT = BATCHWORKFLOWSTATE.ALLOWCOMMIT
from dbo.BATCHTEMPLATE
inner join dbo.BATCHWORKFLOW on BATCHTEMPLATE.BATCHWORKFLOWID = BATCHWORKFLOW.ID
inner join dbo.BATCHWORKFLOWSTATE on BATCHWORKFLOW.ID = BATCHWORKFLOWSTATE.BATCHWORKFLOWID
where BATCHWORKFLOWSTATE.ISINITIALSTATE = 1 and BATCHTEMPLATE.ID = @BATCHTEMPLATEID
return @ALLOWCOMMIT
end