Viewing and Editing Synonym Attributes

How to:

Reference:

The Synonym Editor enables you to view and edit the attributes of a synonym.


Top of page

x
Procedure: How to View and Edit Synonym Attributes

To view and edit synonym attributes:

  1. Double-click a synonym, or right-click it and click Open.

    The Synonym Editor opens to the Field View tab, which shows a hierarchy of segments and columns on the left, with the attributes and values of the selected item on the right.

    The attributes available depend on the type of synonym.

    The values for Format, Expression, Description, and Nulls are viewable in the hierarchy with the columns. To edit these values, use the corresponding attribute fields on the right-hand side of the Synonym Editor.

  2. You can change the attribute values by typing in new values or by using the drop-down menus and check boxes.

    The Synonym Editor does not let you make any changes that would render the synonym unusable. Therefore, you cannot edit any value field that is highlighted gray. In addition, if a change does not have proper syntax or format applied, the field may appear in red text. Messages and warnings appear if you try to save a file that contains an error.

  3. Save changes by clicking Save from the Quick Access Toolbar.

    Note: You can multi-select fields to change attributes for multiple fields in a single operation. The display changes to show only those attributes that can be changed.

  4. Close the Synonym Editor by clicking the X.

Note: If you close the Synonym Editor without saving your changes, you are prompted to do so.


Top of page

x
Reference: File Attributes Summary

The image below is an example of an SQL data source with the synonym file name selected.

File name selected

Note: Information about the attribute that has focus is displayed at the bottom of the attribute list. In this case, an explanation of the SUFFIX attribute appears.

Synonyms can have the following file attributes:

General
SUFFIX

Identifies the type of synonym or data source.

FDEFCENT

Defines the default century value, specifying a century number for handling cross-century dates.

Note: Use the default setting (0) unless you wish to retrieve data from a earlier century (for example, 19xx).

FYRTHRESH

Defines the base years, to represent the lowest year to which the century value applies (FDEFCENT).

Note: Use the default setting (0) unless you wish to retrieve data from a earlier century (for example, 19xx).

REMARKS

Enables you to include descriptive information at the file level and specify multiple language descriptions for the synonym. Remarks are displayed along with the file name during reporting.

DATASET

Identifies the location of the data source to be used in the file name, including the extension and the location of the data file.

Note: The attributes available depend on the type of synonym.



x
Reference: Segment Attributes Summary

If a synonym segment is selected, the attributes listed below are available.

Note: Information about the attribute that has focus is displayed at the bottom of the attribute list.

General
SEGMENT

Is the name of the segment.

ENCRYPT

Check this box to scramble field values in the current segment in order to protect it from unauthorized examination.

SEGTYPE

Specifies the type of relationship that a segment has to its parent, and indicates which of the segment fields are key fields and in what order they are sorted.

Type. Identify the segment type and sorting options from the Type drop-down list.

Keys. Records are sorted in a data source by key fields. Enter the names of key fields that you want to use for sorting. For example, no two employees can have the same employee ID number, so you can use that field as the key. A segment instance can have more than one field that makes up the key. That is, two or more field values may be used to distinguish records.

SEGSUF

SEGSUF is used when part of the data source being described by the synonym is of a different data source type than that declared for the entire structure.

Note: SEGSUF is the data source type of a segment and any descendants it might have, where that type differs from the SUFFIX value.

Miscellaneous
DESCRIPTION

Contains a description or comments about the segment.

CRFILENAME

Is the name of the cross-referenced data source.

CRSEGNAME

Is the name of the cross-referenced segment.

CRKEY

Identifies the common join field for the cross-referenced segment.

Note: These cross-referenced values (CRFilename, CRSegname, CRKey) are available for FOCUS data sources.

SEG_TITLE_PREFIX

An optional attribute that enables you to provide the title prefix for the segment fields that appear in reports. You can split the text across up to five separate title lines by separating the lines with a comma.

Adapter Specific

Adapter Specific fields are shown if an Access File component has been generated with the synonym.

CARDINALITY

Defines how many members of a dimension can be retrieved for a report.

TABLENAME

Identifies the table or view. It may contain the owner ID, as well as the table name. For some synonyms, it must also contain the data source name. This value may be a variable.

CONNECTION

Indicates the host server or data source for synonyms. This value may be a variable.

KEYS

Identifies the names of the columns that constitute the primary key.

KEYORDER

Identifies the logical sort sequence of data by the primary key.

WRITE

Specifies whether write operations are allowed against the table.

DBSPACE

Identifies the storage area in which the table resides.

PERSISTENCE

Specifies the type of table persistence and related table properties. This is optional for database management systems that support volatile tables, and required otherwise.

Note: The attributes available depend on the type of synonym.



x
Reference: Column/Field Attribute Summary

If a column or field in a synonym is selected, the attributes listed below are available. The available attributes depend on the type of synonym. Information about the attribute that has focus is displayed at the bottom of the attribute list.

General
FIELDNAME

Is the name of the column.

ALIAS

Assigns an alternative name for a column, or the real column name for a DBMS synonym.

For file data sources, a special reserved ALIAS of INSTANCE means the associated FIELD will show the name of the file when it is read.

When a FIELDNAME of RECTYPE is used the ALIAS contains the value that identifies the record type.

MISSING

Controls how null data is handled, that is, if no transaction value is supplied.

TITLE

Supplies a title to replace the column name that is normally used in reports and enables you to specify multiple language titles for the column or field.

ACTUAL

Describes the type and length of data as it is actually stored in the data source.

USAGE

Describes the data type and format for the column for usage or display.

Note: Additional attributes, DEFCENT and YRTHRESH, are available if the Usage field is set to Date, Time, or DateTime (Timestamp) format. Use these attributes to enter the century and year threshold values for the column or field.

Miscellaneous
DESCRIPTION

Contains a description or comments about the column or field.

ACCEPT

Specifies criteria for validating data.

  • OR enables you to specify an acceptable value.
  • FROM-TO enables you to specify a range of acceptable value fields.
  • FIND enables you to supply file and field names to instruct where to search for a data source and for a list of acceptable values. You supply the field name of the data field for which the validation criteria are being assigned, the file name of the target FOCUS data source where the field can be found, and the field name of the target data field that contains the validation criteria.

    FIND is only available for FOCUS data sources and does not apply to OLAP-enabled synonyms. Also note that, in the Maintain environment, FIND is not supported when developing a synonym.

WITHIN

Contains the name of a field to be included in a dimension.

FIELDTYPE
  • I - Index identifies an indexed column in a FOCUS database.
  • R - Read only indicates a read-only column. This setting is useful for columns that are automatically assigned a value by the RDBMS.
ACCESS_PROPERTY

Specifies access options for the column data.

  • INTERNAL defines a column that does not appear in sample data or in the list of available columns. Restricts the field from showing in any of the field Lists in the reporting tools.
  • NEED_VALUE defines a column that requires a value to access the data.
  • Select By defines a column by value, range, or multi-values.
  • AUTHRESP defines a column that describes the result of an authentication operation. Correct response values must be provided in the ACCEPT attribute (using the OR predicate if more than one value is acceptable).

    This value is not currently used by DataMigrator.

  • AUTHTOKEN defines a column that contains a response token to be passed as an input value to the operation to be executed.

    This value is not currently used by DataMigrator.

HELPMESSAGE

Appends a help message to a column.

This attribute is not used by WebFOCUS.

SCD Type

Sets slowly changing dimension attributes. This option is only available for existing relational targets and is only used by a flow when SCD is enabled in the target object.

A surrogate key is the KEY column in the table and has an SCD type of blank. Other columns with a blank SCD type have no SCD processing done to them. In a synonym, this column will always appear first, even if it is not the first column in the table.

Note: The surrogate key must be an integer. If the column is identified in the synonym as read-only and Auto increment, then the database native processing is used to assign surrogate key values. If it is not so identified, then DataMigrator processing assigns values for this column, incrementing for each new row added.

  • Logical Key Field. Is the source database keys. Multiple columns may comprise the key.
  • Begin Date/End Date for Type II changes. Indicates date range for the row values. A null end date indicates the row is current. If you use Begin and End Date, the End Date column must be created as nullable, unless you override the default End Date value of NUL with a value for &&CM__SCDAEDATE.

    The data type must be either a Date format or a Date and Time format, however the formats of the two fields must be identical.

    Begin/End Date values for Slowly Changing Dimensions can also be Datetime or Timestamp values.

  • Change Flag. For Type I changes, a value is assigned when a row is updated. If a value is not assigned in Target Transformations for the Date and Datetime columns, the current date or timestamp is assigned automatically.
  • Activation Flag. Indicates if the row is current.

    This field must be an integer. Valid values are:

    1

    Indicates that a record is active.

    0

    Indicates that a record is inactive.

  • Type I (overwriting history) designates columns whose database values are overwritten with new values.
  • Type II (preserving history) designates columns whose database rows are flagged as inactive or assigned an end date. New rows are inserted with the new values.
  • blank (non-key permanent columns) indicates that database values are not changed.
USE_STYLE

The name of the style.

The attributes available depend on the type of synonym.

Adapter Specific

AUTOINCREMENT

Indicates that the field is automatically incremented by the relational database when rows are inserted. This option is only available for selected relational databases. When selected, the field must also be identified with a field type of read-only.

The following attributes are only used if AUTOINCREMENT is checked.

  • START. Indicates the starting value for this AUTOINCREMENT field. If not specified, 1 is used.
  • INCREMENT. Indicates the increment value for this field. If not specified, 1 is used.
  • SEQUENCE. Is the name of the corresponding database SEQUENCE object for this field. This option is only available for ORACLE tables.


x
Reference: File Listener Attributes

The image below is an example of a Flat File data source with DATA_ORIGIN of LISTENER.

Flat file example

A Flat File data source may have the following attributes:

Data Allocation
Connection

The name of a connection for a flat file source that identifies an FTP or SFTP server. This field is optional. If not specified, the file resides locally.

DATA_ORIGIN

Indicates the origin of data described by the synonym.

FILE. Indicates that a file (or collection of files if a wildcard is used in the dataset parameter) is read once. This is the default.

LISTENER. Indicates that files are read as they appear, as specified in the remainder of the File Collection Parameters.

TAIL. Is reserved for future use.

Directory

Indicates the application directory to check for files. To use a directory that is not under the app root of the server, map that directory.

Note: The application directory does not have to be in the application path of the server.

Name

Indicates the name of the file. May include wildcard characters. The default is *.

Extension

Indicates the file type that the listener is checking. The default is .ftm.

Read Limits

Maxfiles

Indicates the maximum number of data files processed by the request. The default is 99999999.

Maxrecs

Used only for the data origin of TAIL. Indicates the maximum number of records processed by the request. The default is 99999999.

Discard

KEEP. Keeps the file. This option is only available for a pickup type of Trigger or Monitor.

The parameters below only apply to Origin of Listener.

Listening Parameters

Polling

Indicates the polling interval (in seconds) for new files arriving in the specified directory. For example, a polling interval of 10 means the directory is scanned every ten seconds for new files. The default is 10 seconds.

Timeout

Indicates the timeout interval (in seconds) before a flow or other read request should wait before terminating. For example, a timeout value of 100 means if no new files arrive in the directory after 100 seconds, the job should stop. The default is 10 seconds.

Pre Processing Actions
Pickup

Indicates the mechanism used to pick up files from their directories. The options are:

IMMEDIATE. Processes the file as soon as it is detected. This is the default.

TRIGGER. Processes the file when a trigger file is detected. This setting requires an additional setting for the trigger file extension.

A trigger is typically used when processing needs to be delayed. For example, by waiting until this secondary file appears while a large file is being copied into a directory, the trigger file indicates when processing can begin.

MONITOR. Monitors the file as soon a file change is detected.

The files themselves are not read, only their name and location are recorded. Processes files and sub-directories when they are added, changed, or deleted.

Trigger

When Pickup strategy of trigger is used, indicates the trigger file extension. The trigger file extension is added to the full name of the file being listened for. For example, if the trigger file extension is .trg, the trigger file for a data file named input.dat would be input.dat.trg. There is no default value.

Note: For VMS only use an underscore. For example, input_dat.trg.

Post Processing Actions

Discard

Indicates what to do with the file after it has been processed by a file agent. The options are:

DELETE. Deletes the file.

ARCHIVE. Moves the file, while adding a timestamp to the name, to a specified directory. This is the default.

KEEP. Keeps the file. This option is only available for the Trigger pickup type.

Archive

When Discard strategy of Archive is used, this indicates the directory to use to archive the files.



x
Reference: Prototype File Monitory Synonym

A prototype synonym is provided as ibisamp/filemntr.mas for a user with the File Listener pickup strategy Monitor. To use this synonym, copy it to an application directory in your application path and edit the File Listener parameters as needed. At a minimum, edit the value for DIRECTORY to point to the application directory (or mapped application name) that you want to monitor. Edit the NAME and EXTENSION values to show the file name (or * for all names) and extensions that you want to monitor.

This synonym contains fields with special values for the ALIAS, as described below.

The properties of the prototype synonym are shown in the following image.

Prototype synonym properties


iWay Software