Enumeration Mapping for Data Types

NOTE: This is a topic for advanced users. This level of details is not required for your average system.

In the Hyper Historian configuration database, data types (such as Boolean or integer) are represented by a number. This is commonly referred to as enumeration (or "enum"). These numbers appear both in the database and in files exported from Workbench. The table below maps which numbers go with what data types.

In most cases, you will not need to worry about the enum mapping for data types. You might need this information if you are creating your own import files (CSV, Excel, or XML) or are updating the Hyper Historian configuration database manually. Note that manually editing import files or the configuration database is not recommended and should be done at your own risk.

The enum mapping changed between version 10.95 and 10.96. Both mappings are listed below. Note that even when upgrading from 10.95 and 10.96 or later, the database upgrade process will take care of the enum change on its own. There is no need to manually update these numbers in the configuration database when doing an upgrade.

Note that version 10.95 Workbench export files do not support being imported into a later version. This feature was added in version 10.96. The only supported  way to upgrade version 10.95 configurations to a later version is to upgrade the configuration file in Workbench, the installation, or the Configure System utility. However, if you find that you must import a 10.95 file into a 10.96 or later system, you must update the data type enum numbers per the table below. Note that this does not guarantee that the file will be importable. Other changes may be required.

 

Data Type

Enum Mapping in 10.96+

Enum Mapping in 10.95

Native

0

0

Boolean

13

3

Int8

3

5

UInt8

7

6

Int16

4

7

UInt16

8

8

Int32

5

9

UInt32

9

10

Int64

6

11

UInt64

10

12

Float32

2

13

Float64

1

14

String

11

18

Duration (TimeSpan)

16

20

DateTime

18

21

BooleanArray

141 (Boolean | 0x80)

131 (Boolean | 0x80)

Int8Array

131 (Int8 | 0x80)

133 (Int8 | 0x80)

UInt8Array

135 (UInt8 | 0x80)

134 (UInt8 | 0x80)

Int16Array

132 (Int16 | 0x80)

135 (Int16 | 0x80)

UInt16Array

136 (UInt16 | 0x80)

136 (UInt16 | 0x80)

Int32Array

133 (Int32 | 0x80)

137 (Int32 | 0x80)

UInt32Array

137 (UInt32 | 0x80)

138 (UInt32 | 0x80)

Int64Array

134 (Int64 | 0x80)

139 (Int64 | 0x80)

UInt64Array

138 (UInt64 | 0x80)

140 (UInt64 | 0x80)

Float32Array

130 (Float32 | 0x80)

141 (Float32 | 0x80)

Float64Array

129 (Float64 | 0x80)

142 (Float64 | 0x80)

StringArray

139 (String | 0x80)

146 (String | 0x80)

DurationArray (TimeSpanArray)

144 (Duration | 0x80)

148 (Duration | 0x80)

DateTimeArray

146 (DateTime | 0x80)

149 (DateTime | 0x80)                  

Note: The information in parentheses indicates how the value was derived. For example, in version 10.96 and later, the enum value for the BooleanArray type is 141, which is the enum for Boolean (13) combined (bitwise OR’d) with hexadecimal value 0x80.