Configuring Import: Events CSV Commands

Use the Import File: Events CSV command to import comma-separated values (.csv) files containing events data into your CygNet Measurement system. Results of the import can be viewed via the Raw Data control (Events data view). Prior to executing the import command, you can optionally configure and edit the events .csv file to prepare it for successful importation into FMS, and customize it using an .idf file. The file to use for the import is defined by the value of the Import file directory parameter.

CygNet Measurement provides a sample CSV file for events data (SampleEventsImport.csv) that you can adjust and use to create CSV files for new imports. The sample .csv file is located in the CygNet\Services\FMS\ImportSamples folder on your host server.

In addition, you can optionally define details about how items in your events .csv file are imported into FMS and how they will appear in the imported file, as well as what values are required for successful import. To do this, column and data source settings can be customized using an import definition file (.idf). A sample of this file for events data (CxFmsImportCsvEvents.idf) is also provided by CygNet Measurement. The sample .idf files are located in the CygNet\Services\FMS\ImportSamples folder on your host server.

Note: An import definition file (IDF) allows you to customize how data is imported into your system via CSV files. See Using an Import Definition File for more information.

See FMS Commands and Import: Events CSV for more information about this command.

See Scheduling FMS Command Tasks in the MSS for more information about scheduling commands.

See FMS ActiveX Controls and CxHmiFms for more information about using commands via FMS ActiveX controls on CygNet Studio or CygNet Vision screens.

See CxFms for more information about scripting commands.

Command Definition Properties

The following command definition properties apply to Events CSV File Import commands.

Property Description

Command type

For system commands, this property will be read-only and will display the selected command type.

See FMS Commands for more information about command types.

Priority

Select a processing queue Priority for the command from the drop-down menu.

Options from least to greatest priority are as follows.

  • Low level
  • Medium level
  • High level
  • User initiated transaction
  • Admin initiated transaction

Default value is Low level processing queue priority.

Logging

Select a Logging level for the command results from the drop-down menu.

Options are as follows.

  • Low — displays errors
  • Medium — displays errors and warnings
  • High — displays errors, warnings, and status

Default value is Low level logging when scheduling a command in the MSS.

Default value is High level logging when creating or running an ad-hoc command in FMS Explorer.

Command Parameters

The following command parameters apply to Import: Events CSV commands, when creating or editing commands in FMS. See Events Import CSV Files for more information about setting up your events .csv file for import.

Parameter Value

Import file directory

Enter the directory location of the Events import file.

Type in the value or click ... to access the Browse for Folder dialog box, and browse to the directory location.

Note: The directory specified is relative to the computer hosting the FMS.

This parameter is required.

Import file mask

If specified, only files meeting the file mask will be considered for import.

Type the file mask name.

Default file mask value is "*" (multiple character wildcard).

This parameter is optional.

Processed files retention (days)

If specified, the files that have been processed will be deleted after the specified number of days. If not specified, processed files will never be deleted.

Type the number of days.

This parameter is optional.

Unit set

If specified, select a unit set in which to view the data.

Options appear in the drop-down menu, which is populated by the unit sets defined in the service. See Configuring Unit Set Definitions for more information.

This parameter is optional.

Notes:

If the unit set is specified with the command parameter AND in the .csv file, the value specified in the .csv file prevails, and overrides the command setting.

If no unit set is specified with the command parameter, units may be specified in the .csv file for included event items using units.

If no unit set is specified with the command parameter, and no units are specified in the .csv file, the default unit set (as configured in your system) will be used.

Comments

If specified, the comments will be part of the audit record for the file import. Type comments regarding the import.

This parameter is optional.

Configuring Events Import CSV Files

Note: Prior to importing an events .csv file, the following conditions must be met for each Node for which you are importing data.

Preparing the CSV Import File

Include the DateTime column in the import file to apply imported events data to the record for the corresponding date and time.

Use the following procedure to prepare an events import .csv file for import into FMS. Sample .csv files are provided for your use in the CygNet\Services\FMS\ImportSamples folder on your host server.

To Configure and Edit an Events Import CSV File

Once generated, you can edit the events import .csv file as follows, prior to importing it into FMS.

  1. Open a .csv file for your events import.
  2. Edit default column entries, using your .csv editor. All default events import .csv columns are noted in the table below.
  3. Insert additional columns into your file, as desired. Available events import .csv columns are described or referenced below.
  4. Edit any events items desired (e.g. units, description, etc.), in preparation for importing the file to FMS.
  5. Save and Close the .csv file when you are done.
  6. Optionally prepare an IDF to customize your import. See Using an Import Definition File for more information.

Events Import CSV Columns

The columns included in the sample events .csv file provide an example of which values may exist in the import file. You can copy and edit the .csv file to prepare it for import, and further customize the import using an .idf (sample file also provided) to define how data is imported into your system, including defining custom column names and specifying values required for successful import. The .csv and .idf files in conjunction work to import data into your system in the format most suitable for your usage.

Default Events Import CSV Columns

The following table lists the columns reflected in the .csv sample file by default, for which values may exist in the events import file. The list is provided for reference, prior to user-customization. See FMS Events Data Items, FMS Configuration Data Items, and FMS History Data Items for additional data item options.

Column* Data Item Description
Device Device - The device name
DateTime EventDateTime - The date/time for which to import and update the events record

Units

eFMS_EVENT_ENTRY_UNITS - Units associated with the event

Category

eFMS_EVENT_CATEGORY - The event category, for example:

  • eFMS_EVENT_CAT_CONFIG - Configuration events
  • eFMS_EVENT_CAT_CONFIG_SPECIAL - Special configuration events
  • eFMS_EVENT_CAT_DEVICE - Device events
  • eFMS_EVENT_CAT_CUSTOM - Custom events
  • eFMS_EVENT_CAT_PV - Process variable events
  • eFMS_EVENT_CAT_CALIBRATION - Calibration events
  • eFMS_EVENT_CAT_VERIFY_CALIBRATION - Verify calibration events
  • eFMS_EVENT_CAT_FREEZE - Freeze events

See FMS Events Data Items for more information about event category enumeration values.

Type

eFMS_EVENT_TYPE - The event type, for example:

  • eFMS_CFG_BASE_PRESSURE - Base pressure

  • eFMS_CFG_BASE_TEMPERATURE - Base temperature

  • [Other selected data item events, as applicable]

See the Event Types table in FMS Events Data Items for more information about event type enumeration values. The event types table contains a list of valid values and also provides links to other valid tables of FMS data items, including FMS Configuration Data Items, FMS History Data Items, and a topic describing Special Configuration Events.

ValueType

eFMS_EVENT_VALUE_TYPE - Type of event value, for example:

  • eFMS_VALUE_TYPE_NUMERIC - Numeric
  • eFMS_VALUE_TYPE_STRING - String
  • eFMS_VALUE_TYPE_NONE - None

Value1

eFMS_EVENT_VALUE_1 - Event value 1, for comparison

Value2

eFMS_EVENT_VALUE_2 - Event value 2, for comparison

AdditionalInfo

eFMS_EVENT_ADDITIONAL_INFO - Additional event information

SequenceInfo

eFMS_EVENT_SEQUENCE_INFO - Event sequencing information

*Column names are configurable to appear as user-provided values; default sample file values are listed.

Back to top

Additional Events Import CSV Columns

Additional column headers can also be included in the events import .csv file, as appropriate for your usage. Columns can be included for any supported FMS Events, Configuration, or History data items for which you have data in your system. See FMS Events Data Items, FMS Configuration Data Items, and FMS History Data Items for a complete list of data items which could appear in your events import .csv file.

Customizing the CSV Import File

In addition to editing the .csv file content, you can use an import definition file (.idf) to define details about how the items in your events .csv file are imported into FMS and how they will appear in the file. To do this, customize the column and data item settings (for example) using an .idf. See Using an Import Definition File for more information.

Back to top