Data Model > Accessing the UNICOM Intelligence Data Model > Working with the Case Data Model > General information > Data types
 
Data types
The Provider implements data types using the MDM type enumeration:
Enum MDMLib.DataTypeConstants
mtNone = 0x0000
mtDouble = 0x0006
mtLong = 0x0001
mtText = 0x0002
mtCategorical = 0x0003
mtObject = 0x0004
mtDate = 0x0005
mtBoolean = 0x0007
mtLevel = 0x0008
End Enum
The Case Data Model does not implement the data type None, because it is reserved for variables in the Metadata Model that do not require case data storage. At present the Provider implements all of the data types except Object. The data types are implemented internally as follows:
Data types
None
Used to indicate a null, but not assigned as a type to any variables.
Double
A 64-bit (double precision) floating-point number with a maximum of 15 digits of precision.
Long
A 32-bit signed integer.
Text
A character string. The maximum length of a text variable is dependent on the DSC. The string may or may not support Unicode, depending on how the CDSC has implemented its storage. The Provider implements all strings using Unicode.
Categorical
A single or multiple categorical response type. The maximum number of responses available varies between DSCs. A categorical response is implemented in the Provider as a string, in which the responses are formatted within curly braces, ({, }), with each response delimited by a comma. For example, {2,3,8} represents the responses 2, 3, and 8. Depending on how the data was collected, the order of the responses in the string can be the order in which they were chosen in response to the question and this can be important for analysis.
Date
A 64-bit OLE Date. The OLE date type contains both date and time and it is represented using the DATE type.
Object
Not implemented.
Boolean
A Boolean value of either True or False. This is implemented internally using VARIANT_BOOL. However, when a Boolean is converted to a Long or a Double, it will be converted to 1 for True and 0 for False.
Level
A hierarchical value. A level contains a child recordset.
UNICOM Intelligence data type mappings
This table defines how UNICOM Intelligence Data Model data types map to the preferred VB6, VB.Net, Visual C#, and Visual C++ data types.
UNICOM Intelligence Data Model
data types
Visual Basic 6
data types
VB.Net
data types
Visual C#
data types
Visual C++
data types
None
An unassigned variant or a variant assigned empty.
An unassigned object or Nothing.
An unassigned object or null.
A Variant of type VT_EMPTY, VT_NULL
Double
Double
Double
double
Double or a Variant of type VT_R8
Long
Long
Integer
int
Long or a Variant of type VT_I4
Text
String
String
string
BSTR
Categorical
An array of objects with each Object containing a Long.
An array of objects with each Object containing an Integer.
An array of objects with each Object containing an int.
A safe array of Variants. Each variant must contain a Long (VT_14) value.
Date
Date
Date
DateTime
DATE
Object
Object
Object
Object
IUnknown*
IDispatch*
Boolean
Boolean
Boolean
bool
bool
See also
Locale handling in the UNICOM Intelligence Data Model
Identifier naming conventions
Rules for regular identifiers
Data type conversions
System variables