Validate Fields to Include
  • 26 Jan 2023
  • 1 Minute to read
  • Dark
    Light

Validate Fields to Include

  • Dark
    Light

Article summary

Step Details

Introduced in Version4.0.0
Last Modified in Version7.12.0
LocationDatabase

The Validate Fields to Include step is used to display any validation warnings for a Decisions object when being saved to the Database. The step requires the full type name and a list of fields from a Decisions entity representing potential fields that will be updated for an entity.



Properties

Inputs

PropertyDescriptionData Type
Field NamesA list of Field Names represent potential fieldsList of String
Type NameThe full type name for a Decisions objectString

Outputs

PropertyDescriptionData Type
WarningsA list of validation warnings found if the listed field values are updatedString

Example Inputs and Outputs

Field NamesType NameWarnings
String_Field, List_String_Fields, Nulls_AllowedMyApps.ExampleDBStructure
Warnings: "id is not included.  Any uploads will create new entities"
String_Field, List_String_Fields, Nulls_Allowed, ID
MyApps.ExampleDBStructure
No validation warnings
String_Field, List_String_Fields, Nulls_Allowed, ID
ExampleDBStructure
EXCEPTION MESSAGE
Empty String ListMyApps.ExampleDBStructure
Warnings: "id is not included.  Any uploads will create new entities"
String_Field, List_String_Fields, Nulls_Allowed, ID
NULL ValueEXCEPTION MESSAGE
NULL ValueMyApps.ExampleDBStructure
EXCEPTION MESSAGE


Common Errors

Value cannot be null

Values for the Field Names or the Type Name fields cannot be null. Ensure that either field does not have null values as inputs.

Exception Message:

Exception Stack Trace: DecisionsFramework.Design.Flow.ErrorRunningFlowStep: Error running step Validate Fields To Include 1[ValidateFieldWarnings] in flow [Testing Flow]: Value cannot be null. (Parameter 'source') ---> System.ArgumentNullException: Value cannot be null. (Parameter 'source')
   at System.Linq.ThrowHelper.ThrowArgumentNullException(ExceptionArgument argument)
   at System.Linq.Enumerable.Contains[TSource](IEnumerable`1 source, TSource value, IEqualityComparer`1 comparer)
   at DecisionsFramework.Design.Flow.CoreSteps.DataBase.ValidateFieldWarnings.Run(StepStartData data)
   at DecisionsFramework.Design.Flow.FlowStep.RunStepInternal(String flowTrackingID, String stepTrackingID, KeyValuePairDataStructure[] stepRunDataValues, AbstractFlowTrackingData trackingData)
   at DecisionsFramework.Design.Flow.FlowStep.Start(String flowTrackingID, String stepTrackingID, FlowStateData data, AbstractFlowTrackingData trackingData, RunningStepData currentStepData) 
   --- End of inner exception stack trace ---

Was this article helpful?