For both, MS SQL-Server and Oracle databases CNCnetPDM writes data acquired from devices to table RawDataTable (default MTH_RAW_DATA) and/or OnlineDataTable (default MTH_ONLINE_DATA).
Both tables have the following columns (field types are taken from MS SQL Server):
FIELD
DESCRIPTION
[GROUP_ID] [float] NULL
Used to tie together multiple items (status, part counter value, work order…) from a device acquired in a reading cycle. Prefixed with ServiceID, see chapter ‘CONFIGURE CNCNETPDM.INI’ for details. Example: 10000000159
[READING_TIME] [datetime] NOT NULL
Date and time when the data was read from the device e.g. 2016-10-12 11:01:07.000
[DEVICE_NUMBER] [smallint] NOT NULL
Number of the device from which data was received e.g. 1000
[TAG_CODE] [varchar](255) NOT NULL
Tag code for the item acquired from a device see also chapter ‘CONFIGURE CNCNETPDM.INI’ for details. For items Event, Counter, DowntimeReason, Order, Operation and Item the tag code is created by using entries as defined in CNCnetPDM.ini. For items acquired via sections 1-3 the tag codes are created according to the NAME definitions in the INI file for each device. This INI file is automatically generated by your device driver DLL.
Example: Tag code STATUS ist taken from CNCnetPDM.ini. If a telegram that contains multiple values e.g. STATN|3|STATT|Manual| (status number = 3, status text = manual separated by a pipe character ‘|’) is read CNCnetPDM creates one record for every tag name (e.g. STATN) with its value (e.g. 3) in column [TAG_DATA].
[TAG_DATA] [varchar](255) NULL
Data value received from a device for a specific tag code. Examples: TAG_CODE = STATN TAG_DATA = 3
TAG_CODE = STATT TAG_DATA = Manual
[CREATION_DATE] [datetime] NULL
Date and time when device data was received by CNCnetPDM e.g. 2017-04-23 11:20:57.000
[PROCESSING_FLAG] [tinyint] NOT NULL DEFAULT 1
This field is useful for further processing of data from MTH_RAW_DATA for example to update tables with aggregated / condensed values. CNCnetPDM sets the value in this field to 2. When you begin to process the data you can set the field to 1 to get a defined number of records that are processed (new records are continuously coming in from devices)
FIG 1: Database field description MTH_RAW_DATA and MTH_ONLINE_DATA
The following figure shows output of data from CNCnetPDM into table RawDataTable (default MTH_RAW_DATA):
FIG 2: Data received from CNCnetPDM in table MTH_RAW_DATA (MS SQL Server)
In the above example CNCnetPDM has received 8 items from device 1002 in a single telegram that contained TAG_CODE and TAG:DATA in a single line separated by a pipe character ‘|’ e.g. PRGCU|4|PRGMN|4712|…
Items collected in the same reading cycle get the same GROUP_ID value (1). READING_TIME (2) is the time when data was read from the device. DEVICE_NUMBER (3) is created according to the devices settings configured in CNCnetPDM.ini.
If the telegram contains a single value TAG_CODE (4) is created according to the settings in CNCnetPDM.ini. In case of multiple values TAG_CODE is created based on the content of the telegram.
TAG_DATA (5) contains the data value returned by the device for the item. CREATION_DATE (6) is the time when the data was received by CNCnetPDM. PROCESSING_FLAG is automatically set to 2 (not shown).
Note: Please make sure that the columns in your database are set up as shown in the description above. Otherwise CNCnetPDM switches to ‘Offline Mode’ and writes all data to the offline-text-file specified for the service. In this case the reason for the issue can be found out by analyzing log file log_db_YYMMDD.txt in the log file folder of CNCnetPDM.
Privacy notice
This website uses cookies. By continuing to use it you agree to our privacy policy.