When creating a hierarchical taxonomy, if a term's parent matches any other term, regardless of depth, it will be matched to that parent.
For instance, a CSV file containing:
Food, Chinese, Fried noodles
Food, Indian, Samosa
Animal, Chinese, Chicken
Becomes, after import:
Animal
Food
Chinese
Chicken
Fried noodle
Indian
Samosa
Comments
Comment #1
Daniel_KM commentedHi,
Duplicate terms are one of the main problem to resolve in taxonomies imports. Simple taxonomies have only one parent, but in your case, it seems "Chinese" has two parents. It's possible, but currently, taxonomy_csv doesn't know if you want above or :
In fact, you should always indicate all the hierarchy for each term to avoid these type of problem:
or in short way:
Regards,
Daniel Berthereau
Knowledge manager
Comment #2
sliph commentedSorry, I wasn't really clear.
I pass it:
I want:
I get:
How I got around this issue:
Modified:
to be:
And then ran SQL against my drupal DB to remove everything before & including the # in Taxonomy. (This is just an example - I had about 150 taxonomy terms in a similar heirarchy)
Comment #3
Daniel_KM commentedHi,
Happy you've found a solution to import your terms.
In some cases, term "Chinese" may be difficult to use, unless articles are described by more than one term and users think to use more than one word to find something.
I 'm currently working on import of duplicate terms.
Daniel Berthereau
Knowledge Manager
Comment #4
Daniel_KM commentedHi,
New release 6.x-4.1 of Taxonomy csv resolves this issue. It recognizes automatically this type of import and creates the good hierarchy.
Best regards,
Daniel Berthereau
Knowledge manager
Comment #5
Daniel_KM commented