Query To Delete Folder and Dependencies
I want to delete everything associate with this project.
The entities within the project are dependent upon one another in some fashion so attempting to delete something gives me the following error.
Is there a way I can just delete everything in my project using a query?
Comments
-
The following queries will pull in all designer elements (Flows, Rules, etc.) These queries function by setting objects within a Decisions Project to 'deleted', just as a standard deletion would. We'll need to make sure that only items we intend to delete are included in the project.
This query only performs a SELECT, and makes no changes to the database. I would recommend running this prior to the UPDATE query, just to ensure we're pulling the right objects.
SELECT * FROM element_registration WHERE entity_folder_id IN (SELECT entity_id FROM module_resource WHERE module_name ='ProjectNameHere')
This query will take all items associated with the project, and set the deleted field to true.
UPDATE element_registration SET deleted = 'true' WHERE entity_folder_id IN (SELECT entity_id FROM module_resource WHERE module_name ='ProjectNameHere')
Once we run that second query, restart the instance.
It is always best practice to take a database backup prior to running any queries.
Howdy, Stranger!
Categories
- 4.2K All Categories
- 67 General
- 11 Training
- 202 Installation / Setup
- 1.1K Flows
- 106 Rules
- 262 Administration
- 212 Portal
- 490 General Q & A
- 695 Forms
- 333 Reports
- 3 Designer Extensions
- 47 Example Flows
- 52 CSS Examples
- 1 Diagram Tile
- 7 Javascript Controls
- 179 Pages
- 5 Process Mining
- New Features
- 179 Datastructures
- 69 Repository
- 221 Integrations
- 28 Multi-Tenant
- 27 SDK
- 78 Modules
- 56 Settings
- 25 Active Directory
- 12 Version 7
- 35 Version 8
- 83 Lunch And Learn Questions