Defect HC-3024
Dataload error when loading descriptive attribute value longer than 254 chars
Software
Customer case | Applies to | Corrected in |
---|---|---|
CS0116835 | V9.0.1.0 | 9.0.1.12 |
Observed behavior
When loading descriptive attribute values from a CSV into the database, an unchecked length violation causes a SQL exception for \"predefined allowed values\".
Expected behavior
The code should detect the situation where the value is larger than the database definition for that field and handle the situation.
Resolution
The code in CatalogEntryAttributeDictionaryAttributeMediator uses the supplied attribute value id if available, otherwise it will be set to the attribute's value by copying that field.
The problem occurs when the identifier field's length is smaller than the copied value. The code was updated to truncate the value for the identifier before attempting to insert it into the database. This fix affects the descriptive allowed value attributes only.