cancel
Showing results for 
Search instead for 
Did you mean: 

How to impex import classification values of type range ?

former_member224482
Active Contributor
0 Kudos

I would like to import product features associated to a category using the numeric type range. The difficulty is about providing the range values using ImpEx.

I use the following ImpEx test setup :

 INSERT_UPDATE ClassificationSystem;id[unique=true]
 ;CS
 
 INSERT_UPDATE ClassificationSystemVersion;catalog(id)[unique=true];version[unique=true]
 ;CS;CSV
 
 INSERT_UPDATE ClassificationAttributeUnit;code[unique=true];systemVersion(catalog(id),version)[unique=true];symbol;unitType;conversionFactor
 ;CAU;CS:CSV;"³";CAUT;1
 
 INSERT_UPDATE ClassificationAttribute;code[unique=true];systemVersion(catalog(id),version)[unique=true]
 ;CA;CS:CSV
 
 INSERT_UPDATE ClassificationClass;code[unique=true];catalogVersion(Catalog(id),version)[unique=true]
 ;CC;CS:CSV
 
 INSERT_UPDATE ClassAttributeAssignment;classificationClass(catalogVersion(catalog(id),version),code)[unique=true];classificationAttribute(systemVersion(catalog(id),version),code)[unique=true];attributeType(code);multiValued;unit(code,systemVersion(catalog(id),version),unitType)[unique=true];formatDefinition;range
 ;CS:CSV:CC;CS:CSV:CA;number;false;CAU:CS:CSV:CAUT;"######0.000";true
 
 INSERT_UPDATE Product;code[unique=true];catalogVersion(Catalog(id),version)[unique=true];supercategories(code,catalogVersion(catalog(id),version));@CA[system=CS,version=CSV,translator=de.hybris.platform.catalog.jalo.classification.impex.ClassificationAttributeTranslator]
 ;P;CS:CSV;CC:CS:CSV;2

The question is what do I have to write instead of the value 2 to provide the stnd end value of the range.

See screenshot for reference:

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Robin, you can use the comma delimiter for that. You can see a few examples in products-classifications_en.impex in the electronicstore/import/sampledata folder. For example the import of 346944 got a range for the Input frequency.

UPDATE: Apparently this is not enough... I've took your example and tested it and it didn't worked, you might have figured that out yourself already. Apparently, this solution only works if you mark your ClassAttributeAssignment as a range as well as a multi-valued. This is actually a different model definition then you would like, but at least the hMC seems to take it (range is prioritized in the view over the multivalued).

former_member224482
Active Contributor
0 Kudos

Took me some time to figure it, but the range values seems to only works with ClassAttributeAssignment.multiValued = true.

P.S. Backoffice Refresh button does not work on the products attributes tab. Have to close the browser to refresh the product data.

Former Member
0 Kudos

right 🙂 parallel editing here...

Answers (0)