05-09-2023 08:54 AM
Hi
I have a dashboard that executes an Import > Validate > Process using a business rule.
In my workflow I am currently using Workspace, Import, Validate, Process, Confirm:
I would like to just use Workspace, Confirm, but it gives me the following error: "Cannot execute step because the specified step classification doesn't exist for the workflow profile."
Is there anyway around this?
Thanks,
Mark
Solved! Go to Solution.
05-09-2023 11:40 AM
I see, so that is not possible on a single Workflow. You could have 2 Workflows though:
Workflow 1 = Workspace
Workflow 2 = Import, Validate, Process, Confirm
These could be on the same Base Input Profile and control the access through the Access Group.
05-09-2023 10:37 AM
How are you calling the confirm execution?
05-09-2023 10:42 AM
I'm not automating that part - may even drop the confirm step at this stage.
05-09-2023 10:47 AM
To clarify - are you saying that you want to drop Import, Validate, Process from the steps going across the top of the Workflow? If so, this will likely need an enhancement in order to add that Workflow Name (Workspace, Confirm) to the Import.
05-09-2023 10:49 AM
Yeah, that is what I'm asking. to be fair, I'm not precious about confirm. I would be happy with just Workspace.
05-09-2023 10:52 AM
Ok, if it's just Workspace then you should be able to change the Workflow Name on that Import. Just be aware that this changes the Workflow Name for all periods so anything done in other steps in previous periods wouldn't be visible after this change (but will still be in the tables).
05-09-2023 10:58 AM
When I do that, I get the following error when my business rule runs:
"Cannot execute step because the specified step classification doesn't exist for the workflow profile."
05-09-2023 10:59 AM
We probably will need to see the rule detail in order to be able to diagnose the issue. Can you share that?
05-09-2023 11:04 AM - last edited on 05-10-2023 04:10 AM by JackLacava
Public Function Main(ByVal si As SessionInfo, ByVal globals As BRGlobals, ByVal api As Object, ByVal args As ExtenderArgs) As Object
Try
Select Case args.FunctionType
Case Is = ExtenderFunctionType.ExecuteDataMgmtBusinessRuleStep
'Prepare Parameters
Dim profileKey As Guid = New Guid(args.NameValuePairs.XFGetValue("ProfileKey"))
Dim scenarioId As Integer = ConvertHelper.ToInt32(args.NameValuePairs.XFGetValue("ScenarioId"))
Dim timeId As Integer = ConvertHelper.ToInt32(args.NameValuePairs.XFGetValue("TimeId"))
Dim wfClusterPK As New WorkflowUnitClusterPk(profileKey, scenarioId, timeId)
'Execute extraction
Dim piLoadTransform As LoadTransformProcessInfo = BRApi.Import.Process.ExecuteParseAndTransform(si, wfClusterPK, Nothing, Nothing, TransformLoadMethodTypes.Replace, SourceDataOriginTypes.FromDirectConnection, False)
'Execute validations
Dim piValidateTransformation As ValidationTransformationProcessInfo = BRApi.Import.Process.ValidateTransformation(si, wfClusterPK, True)
Dim piValidateIntersections As ValidateIntersectionProcessInfo = BRApi.Import.Process.ValidateIntersections(si, wfClusterPK, True)
'Execute Load & Process
Dim piLoadCube As LoadCubeProcessInfo = BRApi.Import.Process.LoadCube(si, wfClusterPK)
Dim piProcessCube As ProcessCubeProcessInfo = BRApi.DataQuality.Process.ExecuteProcessCube(si, wfClusterPK, StepClassificationTypes.ProcessCube, False)
End Select
Return Nothing
Catch ex As Exception
Throw ErrorHandler.LogWrite(si, New XFException(si, ex))
End Try
End Function
05-09-2023 11:13 AM
Ok, looks like you are trying to automate the Import, Validate and Process. I also thought that you wanted only the Workspace step so we removed those steps.
Can you clarify what steps you want (Workspace, Import, Validate, Process, Confirm) and then which of those you want to automate?
05-09-2023 11:38 AM
I have a dashboard (which is on the Workspace step), on the dashboard I'm loading data into the Cube using a business rule. So I am automating the Import, Validate, and Process steps.
However, from a user perspective, I don't want them to see Import > Validate > Process. So I'm looking to see if it is possible to hide these from the user, I only really want them to interact with the dashboard.
05-09-2023 11:40 AM
I see, so that is not possible on a single Workflow. You could have 2 Workflows though:
Workflow 1 = Workspace
Workflow 2 = Import, Validate, Process, Confirm
These could be on the same Base Input Profile and control the access through the Access Group.
05-09-2023 12:49 PM
Ah ok, that's an interesting option! I'll give that a go.
05-09-2023 02:45 PM
Why not make one workflow which is Import, Validate, Process. However, whichever option you go with the user needs access to that workflow so that they can run it. Then create a dashboard with a button and run that rule you got. I would also add a step to get the workflow info and see if the step you can going to execute is valid for that workflow and then rule the code. If you search for validate interactions here, you'll get an example I posted a while back.
05-10-2023 11:42 AM
Thanks!