Data types in Analytics

The data types supported by Analytics are listed below, including the data sources that the data types can be used with.

The same data type may have a different name in the Data Definition Wizard and the Table Layout dialog box. Both names are shown below.

Analytics data types are grouped into four data categories:

  • Character
  • Numeric
  • Datetime
  • Logical

The Analytics operations that you can perform on a field with a specific data type, and how the field is displayed, are determined by the data category. For example:

  • You can only stratify fields with data types in the Numeric category.
  • Fields with data types in the Character category are left-aligned.

If you use a field of the wrong data type in an operation, Analytics displays an error.

Analytics data type

(Data Definition Wizard)

Analytics data type

(Table Layout dialog box)

Analytics data category

External data source

Additional information

AccPac Accounting Number

ACCPAC

Numeric

ACCPAC

Used in ACCPAC accounting applications. The length of this data field is always 6 bytes. Analytics overrides any other specified length.

ACL

ACL

Numeric

None. This is an Analytics system data type.

An Analytics-generated 12 byte field that stores the results of Analytics computations. It is designed to store large numbers and is not a printable field. Analytics will automatically assign this type to a field when it is appropriate.

ASCII text

ASCII

Character

Windows-based applications

Used for data stored in the ASCII character encoding (American Standard Code for Information Interchange).

Analytics uses extended ASCII which defines 256 printable and non-printable characters. The actual characters available in Analytics are specified by the operating system's default 8-bit code page.

The maximum length of an ASCII field is 32767 bytes.

Basic Floating Point

BASIC

Numeric

Windows-based BASIC applications

Used for floating point data types formatted for the BASIC programming language. The field length of this data type can be either 4 or 8 bytes.

Binary Numeric

BINARY

Numeric

  • PL/1

  • COBOL COMPUTATIONAL-1

  • Fixed binary data type

The maximum length is 8 bytes. The number of decimals is implied and cannot exceed the number of digits specified by the length.

Binary fields of even length are treated as signed binary fields (twos compliment), and odd lengths are treated as unsigned fields (implicit high-order zero bytes are added).

Custom Text Format

CUSTOM

Character

None. This is an Analytics data type that can be assigned by the user as needed.

Used to enable user-defined character substitutions when data is read from the data source. This data type reads data as ASCII text unless there is a substitution character defined in a file named custom.dat.

For more information, see Custom data type.

Datetime

DATETIME

Datetime

This is an Analytics data type automatically or manually assigned to fields that store dates, datetimes, and times.

Used for date, datetime, and time data stored using a variety of different formats, such as YYMMDD, or YYMMDD hh:mm:ss. The Format setting in the field definition specifies how to read datetime data from the data source.

EBCDIC text

EBCDIC

Character

IBM z/OS and OS/400 applications

Used for Extended Binary Coded Decimal Interchange Code (EBCDIC) data, which is an 8-bit character encoding, on IBM server operating systems. The length of this data type is a maximum of 32767 bytes.

Floating Point

FLOAT

Numeric

Windows-based applications

Used for double precision floating-point numbers. The field length of this data type can be either 4 or 8 bytes.

n/a

HALFBYTE

Numeric

Unisys/Burroughs applications

Used for half-byte aligned packed data found in Unisys/Burroughs systems. Signed numbers must follow the Unisys/Burroughs convention. The start position and length of this data type must be specified in half bytes. The start position can be calculated as follows:

(byte_position*2)-1

This data type can only be selected in the Table Layout dialog box.

IBM Floating Point

IBMFLOAT

Numeric

IBM z/OS and OS/400 applications

Used for IBM floating-point data, which is mainly found in mainframe scientific applications. The field length of this data type can be either 4 or 8 bytes long.

Logical

LOGICAL

Logical

This is an Analytics data type automatically or manually assigned to fields that store logical values.

Used for single character fields that represent Boolean data (usually true or false). Analytics can interpret the following sets of values, where the first value evaluates to true and the second evaluates to false:

1/0, T/F, t/f, Y/N, y/n, non-blank/ASCII blank (Hex 20)

PC Binary

MICRO

Numeric

Windows-based applications

Used for unsigned binary numeric data representing integer or long data types. The maximum length is 8 bytes. The number of decimals is the implied number of decimal digits, and cannot exceed the number of digits implied by the length. Micro fields with even lengths are treated as signed binary fields, and fields with odd lengths are treated as unsigned fields.

n/a

NOTE

Character

None. This is an Analytics system data type.

Used by Analytics to store information about the record notes associated with an Analytics table. You cannot define fields using the Note data type.

Numeric (Unformatted)

NUMERIC

Numeric

Windows ASCII or Unicode printable numeric data, or z/OS or OS/400 EBCDIC data that uses the COBOL display data type

Used for printable numeric data that corresponds to the COBOL display type. This field type can include any punctuation, but most commonly includes leading or trailing blanks, an optional leading or trailing sign, embedded commas, and an explicit decimal point.

This data type can contain a maximum of 22 digits plus 18 characters of punctuation, for a total length of 40 bytes, and leading zeros are treated as blanks.

This data type should be used with caution because the number of decimal points specified for the field are applied whether appropriate or not. For example, if you specify 2 decimal places and the values $500.50 and $399 are read, the first value will be interpreted correctly as 500.50, but the second value will be interpreted as 3.99 instead of 399.00.

If the specified decimal places differ from the explicit decimals in the field, the field is rounded to the appropriate number of decimals.

Analytics correctly interprets parentheses and “CR” as negative, but ignores commas and other punctuation, such as dollar signs ($). Signs can be leading or trailing, fixed, or floating.

Packed Numeric

PACKED

Numeric

PL/1 fixed decimal data type or the COBOL computational-3 data type

Used for packed numeric data from mainframe operating systems that stores two numeric digits per byte. The rightmost byte contains a sign indication in the lower half of the byte, usually hexadecimal C for positive and hexadecimal D for negative. (Using hexadecimal B to indicate negative numbers is not supported.) The upper half of the rightmost byte and each half of all other bytes contain one hexadecimal digit that represents the numeric digit of that position in the number.

The length of this data type is a maximum of 12 bytes (23 digits); however, Analytics generates an error message if it encounters a number larger than 22 digits. Consequently, when you define a packed numeric field in the Table Layout dialog box, the number of decimals that you specify in the Dec text box must not result in numbers longer than 22 digits. For example, if your data contains seven-digit figures, you cannot specify more than 15 decimal places (22 digits – 7 digits).

Packed Numeric fields can also be used to store date information in numeric form.

PC DOS Text

PCASCII

Character

Windows

Similar to the ASCII data type. You can use it when the data in a file is created by a DOS application.

The PCASCII characters available in Analytics are specified by code page 437.

The maximum length of a PCASCII field is 32767 bytes.

Note

Do not use the PCASCII data type when the ASCII data type is required. The extended character sets of the two data types are different.

Numeric (Formatted)

PRINT

Numeric

Windows ASCII or Unicode printable numeric data, or z/OS or OS/400 EBCDIC data that uses the COBOL display data type

Used for printable numeric data that corresponds to the COBOL display type. This field type can include any punctuation, but most commonly includes leading or trailing blanks, an optional leading or trailing sign, embedded commas, and an explicit decimal point.

This data type can contain a maximum of 22 digits plus 18 characters of punctuation, for a total length of 40 bytes, and leading zeros are treated as blanks.

This data type should be used instead of the Numeric (Unformatted)/NUMERIC type when the decimal digits are not included for every numeric value. For example, if you specify 2 decimal places and the values $500.50 and $399 are read, this data type will correctly interpret both values (500.50 and 399.00).

If the specified decimal places differ from the explicit decimals in the field, the field is rounded to the appropriate number of decimals.

Analytics correctly interprets parentheses and “CR” as negative, but ignores commas and other punctuation, such as dollar signs ($). Signs can be leading or trailing, fixed, or floating.

Unicode

UNICODE

Character

Unicode data

Used for Unicode character data.

For Unicode data, Analytics uses the UTF-16LE character encoding.

This data type is only available in the Unicode edition of Analytics.

UNISYS Packed

UNISYS

Numeric

Unisys/Burroughs applications

Used to read Unisys/Burroughs byte-aligned packed data. Signed numbers must follow the Unisys/Burroughs convention, and unsigned Unisys packed data should use the Unsigned Packed/UNSIGNED data type. The maximum length of this field type is 12 bytes, or 22 digits.

Unsigned Packed

UNSIGNED

Numeric

IBM z/OS and OS/400 applications

Used for unsigned packed data, which is a data type that stores two decimal digits per byte. The length of this data type is a maximum of 11 bytes or 22 decimal digits. The number of decimal places cannot exceed the maximum number of digits possible for this field.

VAX Floating Point

VAXFLOAT

Numeric

DEC VAX applications

Used for type-D floating-point data from Digital Equipment Corporation’s VAX systems. The length of this data type is either 4 or 8 bytes.

Zoned Numeric

ZONED

Numeric

IBM, DEC, or Honeywell mainframe applications

Used for zoned numeric fields that store one digit per byte, and can be encoded using ASCII, EBCDIC, or Unicode (if you are using the Unicode edition of Analytics).

Leading zeros are retained, and the upper half of the rightmost byte of the field includes the minus sign. The maximum length of a zoned field is 22 bytes.

Analytics automatically detects and adjusts for zoned fields conforming to the IBM, Honeywell, and DEC formats.