Physical fields

In an Analytics table layout, a field that corresponds to actual physical data in a data source is called a physical field.

A physical field, also called a field definition, structures raw field data by specifying metadata information, including:

  • the name of the field
  • the start position of the field in the record
  • the length of the field
  • the data type of the field, which determines how Analytics reads and processes the data stored in the field

Additional information may also need to be specified based on the data type, and the settings you want to provide to override default values. For example, the formatting to apply to numeric fields, or the column title used in views and reports, can either be left blank and a default value is assigned, or you can specify the value to use.

Example of a physical field definition

The example below shows the definition for the Invoice_Amount field in the Table Layout dialog box. In the data preview area, the actual physical data included in the field is highlighted green.

Metadata element Description Value
Name physical field name Invoice_Amount
Type data type Numeric
Start field start position byte position 29
Len. field length 12 bytes
Dec. decimal places 2
Valid Data Types Clickable list of suggested data types

Numeric

includes preview of first value in the field

Format numeric format

(9,999,999.99)

  • numbers 0 to 9 supported
  • thousands separator is a comma
  • decimal separator is a period
  • negative numbers are indicated by parentheses
Width field display width in views and reports 12 characters
Alternate Column Title field display name in views and reports Invoice Amount (two lines)

Define a physical field

You need to define a physical field for each field in a data source that you want to add to an Analytics table layout.

In most cases, the required physical fields are defined for you when you define and import data using the Data Definition Wizard or the Data Access window. However, you can define additional fields manually or you can choose to define all fields in a table layout manually.

Defining datetime fields

Depending on the data source you are working with, datetime information (dates, datetimes, or times) may be stored as character data or numeric data. When you manually define a field that contains datetime information, Analytics treats it as character data by default. To ensure Analytics reads datetime information correctly, you need to select Datetime as the data type, and specify the datetime source format in the Format drop-down list.

Datetime source format

The datetime source format identifies the characters or digits in the source data that represent year, month, day, hour, minutes, and seconds, and any characters used to separate these parts of datetime data.

To match the way datetimes are stored in the source data, you can:

  • select an existing datetime format
  • specify your own datetime format
  • select an existing format and modify it

For example, if December 31, 2014 is stored in the data source as 14-31-12, enter YY-DD-MM as the datetime format so that Analytics can interpret the date values correctly.

For more information, see Formats of date and time source data.

Datetime display format

The datetime source format you select or specify does not affect how datetime values are displayed in Analytics views or formatted in reports. The datetime display format depends on the Date Display Format and Time Display Format settings specified in the Date and Time tab in the Options dialog box.

For more information, see Date and Time tab (Options dialog box).

Defining overlapping fields

In most cases, when you define the physical fields in a record, each byte position in the record is assigned to only one field. At its most basic, defining a table is a matter of defining the start position and length of each field in the record, and one field starts after the previous field ends.

In some cases, however, you may need to define fields that overlap with each other, and some byte positions are used in more that one field. This situation might occur if the structure of the source data is non-standard, or if you want to work with the data in Analytics in a certain way.

For example, you could define the first six positions in a data source as a datetime field with the format DDMMYY, and then separately define a two-byte numeric field in position 3 and 4 for the month. This approach would allow you to access the entire date in one field for aging purposes, and have the month as a separate value in another field for generating monthly totals.

Analytics 14.1 Help