Totara Learn Open Discussions

Delete evidence from completion import

 
Alex Virtue
Delete evidence from completion import
by Alex Virtue - Friday, 7 June 2024, 4:01 AM
Group Partners

A customer has imported some completion data that, after the fact, was found to have been incorrectly formatted.

We're looking for a way to delete the evidence that was created from this import and have so far been unsuccessful.

I can see that it was mentioned in T-12494 and in a discussion thread here but I cannot see any mention of how/where the feature actually exists or how it works.
The discussion thread seems to be talking more about the course completion editor which, as far as I can tell, doesn't do what we need.

Craig Eves
Re: Delete evidence from completion import
by Craig Eves (Totara Support) - Monday, 10 June 2024, 9:13 PM
Group Totara

Hi Alex

There doesn't seem to be a way of bulk deleting evidence items through the front end and the ticket TL-12484 doesn't seem to be related..

This is possible to do through the backend with a query - can you create a support ticket and we can provide this as version and database dependent.

regards

Alex Virtue
Re: Delete evidence from completion import
by Alex Virtue - Tuesday, 11 June 2024, 1:20 AM
Group Partners

"T-12494 Added ability to edit/delete evidence items created through course completion upload…"
This is the portion I was referring to. Seems to be exactly what I'm looking for.

I appreciate the response and will speak to support.

Alex Virtue
Re: Delete evidence from completion import
by Alex Virtue - Tuesday, 11 June 2024, 5:19 AM
Group Partners

For others looking for a solution here was ours.

Please note: SQL scripts are potentially lethal to the functioning of your database. As with any random code you find on the internet, you should verify it does as described before blindly copying, pasting and running. It is highly recommended that you test (in a test environment) and run a database backup before implementing your solution. Just because this solution worked for us, doesn't mean it will for you.

DELETE FROM ttr_totara_evidence_item WHERE typeid in (1,2);

In our case Type ID 1 and 2 are the default evidence import types for course & certification completions, of which we were happy to delete all instances of.