Project

General

Profile

Actions

bug #6343

open

TermVocabularies of OrderedTerms must be OrderedVocabularies

Added by Andreas Müller over 7 years ago. Updated over 2 years ago.

Status:
In Progress
Priority:
Priority14
Category:
data
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Severity:
normal
Found in Version:
Tags:

Description

Updatescript for TermVocabularies of OrderedTerms which are not OrderedVocabularies.

See also https://dev.e-taxonomy.eu/redmine/issues/4821#note-8

===

Otherwise the terms of the following types need to be unordered (see #7340)

Therefore the following script needs to run for them:

UPDATE TermVocabulary
SET DTYPE = 'TermVocabulary'
WHERE termType IN ('SEX', 'DMO', 'MO', 'STG', 'SCO');

UPDATE DefinedTermBase
SET orderIndex = NULL
WHERE termType IN ('SEX', 'DMO', 'MO', 'STG', 'SCO');

Also we may want to set the uri and some iso fields to NULL where empty (see #7445):

UPDATE DefinedTermBase
SET uri = null
WHERE Trim(uri) = '';

UPDATE DefinedTermBase
SET iso639_1 = null
WHERE Trim(iso639_1) = '';

UPDATE DefinedTermBase
SET iso3166_A2 = null
WHERE Trim(iso3166_A2) = '';

UPDATE TermVocabulary
SET uri = null
WHERE Trim(uri) = '';

I did run these scripts on production, integration and test.


Related issues

Related to EDIT - bug #7340: OderedVocabularies are initialised with DefinedTerms ClosedAndreas Müller

Actions
Related to EDIT - bug #7445: Empty term uri and isoXXX fields should be nullClosedAndreas Müller

Actions
Related to EDIT - bug #9477: New ordered terms do not have correct order indexClosedAndreas Müller

Actions
Related to EDIT - feature request #6794: Improve term structureIn ProgressAndreas Müller

Actions
Follows EDIT - bug #4821: Changing order of terms not possibleClosedKatja Luther

Actions
Actions

Also available in: Atom PDF