MarcelBeug's avatar
MarcelBeug
Icon for Community Champion rankCommunity Champion
9 years ago
Status:
Done

Table.AddColumn and Table.DuplicateColumn may display invalid data (types) that can not be loaded

Issue moved from the old issue site (and slightly refined)

 

If you supply a columnType with Table.AddColumn or Table.DuplicateColumn (e.g. Byte.Type), then the Query Editor will also display values that are out of range for the Data Type.
E.g. for Data Type Byte, values >255 are still displayed in the Query Editor, but they won't load to the table when the query is applied, meaning: leaving loaded fields empty in the data model.

 

This differs from Table.TransformColumnTypes which will result in an Expression.Error when data is out of range.

My suggestion would be to use the same apporach for Table.AddColumn and Table.DuplicateColumn.

 

Note: even some automatically created code suffers from this; I'll raise a separate issue for that.

 

6 Comments