The HMIS XML and CSV data formats allow the inclusion of a DateDeleted property on certain data elements to indicate if records have been deleted in the source system. The Data Import Tool (DIT) will use DateDeleted to determine if the data should be deleted in Clarity. This article describes the process the DIT goes through to determine if data should be deleted.
Deletable Data Types
Clients, Enrollments, and Services can be deleted via import through the DIT, as long as the requirements outlined below are met.
In order to delete records in Clarity, the following requirements must be met:
- The record that is being imported must have a value for DateDeleted.
- There must be an existing record in Clarity that the imported data matches up with. When importing a record that does not match with an existing record in Clarity (i.e., a new record), the DIT will skip processing that record and will not create a new record.
- The DateUpdated of the record must be the same or newer than the corresponding record's updated date in Clarity. This is the same standard logic for updating records through the DIT.
- The user that uploaded the file through the DIT must have the right permissions to delete the data. The sections below lists the required permissions for each data type.
Data Deletion Permission Requirements
Certain permissions are required to delete data through the DIT. Without these permissions, the DateDeleted value will just be ignored by the DIT, and the rest of the record will be processed as usual. For a complete list of permissions and their descriptions, visit the Access Role Glossary.
In order to delete client records, the user must have the Delete Any Client permission.
To delete enrollments that are at the same agency as the user uploading the file, the user must have the Delete Agency Programs permission. To delete enrollments that are at a different agency, the user must have the Delete Any Agency Programs permission.
To delete services that are at the same agency as the user uploading the file, the user must have the Delete Agency Services permission. To delete services that are at a different agency, the user must have the Delete Any Agency Services permission.