Deleting Child Records
- If I delete a record in a form (table) that has "child"
records in another form, the child records are not deleted.
Though we have this feature in our long term plans, with Deluge Scripting
you can delete the child records when its corresponding parent records
are deleted from the parent form.
About the application
Deluge Script
About the application
The application Deleting
child nodes comprises of two forms:
- Client form to enter the client name (master form).
- Client Details form to enter each client details (child form
with lookup to the Client form).
Deluge Script
When a record is deleted from the parent form (Client form), the on
delete -> on validate script added to this form will delete all
the child records corresponding to this client, from the Client Details
form. To add the script in the Client form,
- Select the from the Forms tab and click on More Actions
-> On Delete -> Validate
- Use the Delete Records task to delete records from the Client_Details
form with the specified criteria.
on delete { on validate { delete from Client_Details[ Client_Name == input.Name ]; } }
|
The above script will delete the records from the Client Details form
and then delete its parent record from the Client form.
Note: |
Deleting of child records from the on delete ->
on success script is not supported. |
|