Unable to delete a competencies framework

Unable to delete a competencies framework

by Juanma Campos -
Number of replies: 9

Hi everyone. As an administrator I'm unable to delete a Competencies Framework. I always get the message :

The competency framework 'English 1st year' cannot be deleted


What Am I doing wrong? Any idea?

Thanks in advance

Juanma

Average of ratings: -
In reply to Juanma Campos

Re: Unable to delete a competencies framework

by Bohumil Havel -
Picture of Particularly helpful Moodlers Picture of Translators

May be competency framework is used, framework is tree of competency. Some part of tree could be used in plan or course.

Bohus

Average of ratings: Useful (1)
In reply to Bohumil Havel

Re: Unable to delete a competencies framework

by Damyon Wiese -

Yes they cannot be deleted if they are in use. 

Average of ratings: Useful (1)
In reply to Damyon Wiese

Re: Unable to delete a competencies framework

by Juanma Campos -

Thank you both of you and sorry for the delay in replying.

Juanma

In reply to Juanma Campos

Re: Unable to delete a competencies framework

by Jean FRUITET -

If you have an first level admin count and an access to your Moodle database you can do anything with phpMyadmin :>))

1) get the competency framework id (table mdl_competency_framework) of the framework to delete;
2) get all ids linked to this competency framework (table mdl_competency);
3) delete all lines of a lot of other tables like

DELETE `mdl_competency_usercomp` WHERE competencyid = 101 OR competencyid = 102 OR
competencyid = 103 etc.


mdl_competency_relatedcomp

mdl_competency_usercompcourse
mdl_competency_evidence
mdl_competency_userevidence
mdl_competency_userevidencecomp

mdl_competency_templatecomp
mdl_competency_usercompplan

mdl_competency_userplancomp

mdl_competency_coursecomp
mdl_competency_modulecomp

mdl_competency

4) and do not forget to delete also the  competency_plan and competency_template tables (learning plans linked to that competency framework).


Probably a specific tool for administrators would be a better solution!


Average of ratings: Useful (3)
In reply to Damyon Wiese

Re: Unable to delete a competencies framework

by Ricardo Caiado -
Picture of Particularly helpful Moodlers
Hi Damyon,

Same problem here.

Where can I find out where it is being used?

Ricardo
In reply to Juanma Campos

Re: Unable to delete a competencies framework

by Max Brouwer -

I am having the same issue. Did the following steps to create my competency:


  • Create competency framework.
  • Create competency within competency framework.
  • Link comptency to course.
  • Link activities to competence.
  • Link (one) learning plan to competence.

Then the following steps to remove my competency:

  • Remove competency from learning plan.
  • Remove competency from course.
  • Attempt to delete competency from competency framework. Does not work.
  • Check whether courses are linked to competency; no courses are linked to competency.

Is this a bug? I am using Moodle 3.1. This is really annoying because I forgot to fill in the qualitative scale for rating my competencies and now I cannot update it because the competency tree is linked to something. It auto-defaults to some scale (connected/separated learning). 

In reply to Max Brouwer

Re: Unable to delete a competencies framework

by Ricardo Caiado -
Picture of Particularly helpful Moodlers
Any update on this???
In reply to Ricardo Caiado

Re: Unable to delete a competencies framework

by Jason Hollowell -
Picture of Particularly helpful Moodlers

Joining in this thread as I have a competency framework (used nowhere) that cannot be deleted.

This is a bit frustrating as the framework I created was just for learning purposes (for me to figure out how to use the frameworks) and now I want to delete it but can't sad

Any advice here? I know I can delete it from the database, as described earlier, but that can't be the design here. Surely there is a 'proper' way to do this...or this is a design flaw (bug)?

Jason

In reply to Jason Hollowell

Re: Unable to delete a competencies framework

by Jason Hollowell -
Picture of Particularly helpful Moodlers

Just documenting what I've found here

1. I scoured the site to make sure I didn't have an orphan learning plan with the competency it in. Nothing

2. Made sure the learning plan link (from profile page) was empty

3. Checked the data base and in the mdl_competency_usercomp table there is a record for a competency being linked to my id (admin).

I don't know why this remains in the database but it is clearly why I'm not allowed to delete the framework. Apparently it didn't get deleted from the table when I deleted all the learning plans.

Continuing with the test, I deleted that row from mdl_competency_usercomp and BAM! Now I can delete the framework.

So, here is my guess. When the learning plan still existed, I associated the framework in question with it and awarded one of the competencies within it to myself. When I later deleted the framework the assignment to me was not. Maybe this is because I did all of this as admin? Maybe (hopefully) this is not an issue in a 'normal' situation (i.e. a teacher etc. assigning a competency to a student)?

At any rate, I'm back to the beginning where I can start with a clean slate. smile

Regards

Jason

Average of ratings: Useful (1)