SELEZIONARE NewTemplate.ProcessSequence, NewTemplate.MasterProcessID, NewTemplate.WorkFlowProcessID
DA (
SELEZIONARE tblWorkFlowTemplates.MasterProcessID, tblWorkFlowAssignmentsDetail.WorkFlowAssignmentID, tblWorkFlowTemplates.ProcessSequence,
tblWorkFlowTemplates.TemplateMasterID, tblWorkFlowAssignmentsDetail.Completed
Da tblWorkFlowAssignmentsDetail INTERNO UNIRE i tblWorkFlowTemplates SOPRA
tblWorkFlowAssignmentsDetail.WorkFlowProcessID = tblWorkFlowTemplates.WorkFlowProcessID
DOVE tblWorkFlowAssignmentsDetail.WorkFlowAssignmentID = @mWorkFlowAssignmentID
ORDINE da tblWorkFlowTemplates.ProcessSequence
) CurrentTemplate
LA DESTRA SI UNISCE (
SELEZIONARE tblWorkFlowTemplates.MasterProcessID, tblWorkFlowTemplates.ProcessSequence,
tblWorkFlowTemplates.TemplateMasterID, tblWorkFlowTemplates.WorkFlowProcessID
Dai tblWorkFlowTemplates
DOVE tblWorkFlowTemplates.TemplateMasterID = @WorkFlowTemplate
ORDINE da tblWorkFlowTemplates.ProcessSequence
) NewTemplate SU CurrentTemplate.MasterProcessID = NewTemplate.MasterProcessID
DOVE CurrentTemplate.MasterProcessID è nullo O CurrentTemplate.Completed = 0
ORDINE da NewTemplate.ProcessSequence
|