Delete Entities
  • 01 Nov 2024
  • 1 Minute to read
  • Dark
    Light

Delete Entities

  • Dark
    Light

Article summary

Step Details
Introduced in Version4.0.0
Last Modified in Version9.4.0
LocationDatabase

The Delete Entities step removes multiple Entities under the same specified Type Name. Just like the Fetch Entities Step, this step requires a Parent Folder, Type Name, Fetch Criteria, and, if applicable, an Extension Type Name. This step ensures the elimination of the fetched Entities, allowing for the targeted removal of unwanted data.


Properties

Entity Fetch Definition

Property NameDescriptionData Type
Type NameDefine which Type is being fetched by the step. ---
Extension Type NameDefine which Extension Data Type is fetched by the Step, if not a default Type. ---
Fetch CriteriaAllows the user to add new Fetch Criteria by using the Field Name to construct a query-like statement for Decisions to interpret automatically within the step. More than one Fetch Criteria can be configured. ---

Modify Fetch Behavior

Property NameDescriptionData Type
Combine Filters Using AND
This setting will combine the filters set up in the Fetch Criteria section using AND.
---
Read Uncommitted Data
Enabling this feature allows Decisions to read entities in a database that have been changed but not saved.
---

Security

PropertyDescriptionData Type
Respect PermissionsIf enabled, the step will not delete entities until the user has the minimum 'CanUse' permission for that folder.
---

Inputs

This section will display data fields to fetch within the chosen structure as well as the Parent Folder ID.

PropertyDescriptionData Type
Parent Folder IDFolder ID of where the data lives. String



Common Errors

Value Cannot Be Null

When the Type Name is not specified, the step will display the following exception message. To fix this, specify the Type Name of the Entities that need to be deleted.

Exception Message:

Exception Stack Trace: DecisionsFramework.Design.Flow.ErrorRunningFlowStep: Error running step Delete Entities 1[DeleteEntitiesStep] in flow [Display Steps]: Value cannot be null. (Parameter 'key')
 ---> System.ArgumentNullException: Value cannot be null. (Parameter 'key'
 at System.ThrowHelper.ThrowArgumentNullException(String name
 at DecisionsFramework.Data.ORMapper.ORMEntityAttribute.Of(Type i, Boolean inherit
 at DecisionsFramework.Design.Flow.CoreSteps.DataBase.AbstractFetchStep.GetSelectStatementForCriteria(StepStartData data
 at DecisionsFramework.Design.Flow.CoreSteps.DataBase.DeleteEntitiesStep.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 ---

Step Changes

DescriptionVersionReleaseDeveloper Task
Added the "Respect Permissions" setting to the Fetch Entities, Get Count, Fetch Distinct Values, Delete Entities, and Update Entities steps. 8.16November 2023[DT-033517]
Properties were reorganized and names were made consistent.9.4November 2024[DT-042028]

Related Information

Articles:
About Data Structures
Entity Structure CRUD Actions


Was this article helpful?