The problem is located within void CategoricalColumn::insert(const VectorIndex& idx, const TableColumn* column), where only the string values but not the category definitions are copied. To achieve a good behavior, one could use a deviation of void CategoricalColumn::setCategories(const std::vector<std::string>& vCategories), which only appends missing categories (with a potential new ID), e.g. void CategoricalColumn::mergeCategories(const std::vector<std::string>& vCategories)
In addition, possible category values that are not already occurring in the column are getting lost.
This happens when:
window nDialogID -set value=currentTable() -item=editTable;
orcopy currentTable(_nRow, cols{}) -target=editTable();
(see: requirementstool-view-edit-handleEditReq.nprc)
right now, you have to manualy GetDatatypeOfAttribute for the table, read the categories and categorize manualy:
Analysis
The problem is located within
void CategoricalColumn::insert(const VectorIndex& idx, const TableColumn* column)
, where only the string values but not the category definitions are copied. To achieve a good behavior, one could use a deviation ofvoid CategoricalColumn::setCategories(const std::vector<std::string>& vCategories)
, which only appends missing categories (with a potential new ID), e.g.void CategoricalColumn::mergeCategories(const std::vector<std::string>& vCategories)