EventFrame schema
- Last UpdatedMay 02, 2023
- 6 minute read
The columns of tables and table-valued functions from the event frame schema, including name, data type, the information if the field is allowed to have no values, and the primary key, are covered in this topic. The parameters used in table-valued functions are also covered.
Master.EventFrame.Attribute
Returns event frame attributes.
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
ID |
Guid |
No |
Yes |
|
Path |
String |
No |
No |
|
Name |
String |
No |
No |
|
Description |
String |
Yes |
No |
|
ValueType |
String |
No |
No |
|
TraitType |
String |
No |
No |
|
IsConfigurationItem |
Boolean |
No |
No |
|
IsHidden |
Boolean |
No |
No |
|
IsManualDataEntry |
Boolean |
No |
No |
|
DataReference |
String |
Yes |
No |
|
UnitOfMeasure |
String |
Yes |
No |
|
TimeStamp |
DateTime |
No |
No |
|
Value |
Variant |
Yes |
No |
|
Value_Int |
Int64 |
Yes |
No |
|
Value_Double |
Double |
Yes |
No |
|
Value_String |
String |
Yes |
No |
|
Value_DateTime |
DateTime |
Yes |
No |
|
IsValueAnnotated |
Boolean |
No |
No |
|
IsValueGood |
Boolean |
No |
No |
|
IsValueQuestionable |
Boolean |
No |
No |
|
IsValueSubstituted |
Boolean |
No |
No |
|
Error |
String |
Yes |
No |
|
UnitOfMeasureID |
Guid |
Yes |
No |
|
TemplateID |
Guid |
Yes |
No |
|
EventFrameID |
Guid |
No |
No |
Master.EventFrame.AttributeCategory
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
AttributeID |
Guid |
No |
Yes |
|
CategoryID |
Guid |
No |
Yes |
|
Attribute |
String |
No |
No |
|
Category |
String |
No |
No |
Master.EventFrame.AttributeTemplate
Contains event frame attribute templates.
In this table, each event frame template (represented by the column EventFrameTemplateID) is related with its own attribute templates as well as with all inherited attribute templates from its base templates. That means attribute templates are duplicated for each event frame template that contains or inherits them. The Boolean column IsInherited can be used to distinguish between these two types of attribute templates.
Note: The design of the table is different than the table EventFrameTemplateAttribute in PI OLEDB Enterprise where each event frame template is related only with its own attributes.
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
ID |
Guid |
No |
Yes |
|
Path |
String |
No |
No |
|
Name |
String |
No |
No |
|
Description |
String |
Yes |
No |
|
ValueType |
String |
No |
No |
|
TraitType |
String |
No |
No |
|
IsConfigurationItem |
Boolean |
No |
No |
|
IsHidden |
Boolean |
No |
No |
|
IsIndexed |
Boolean |
No |
No |
|
IsInherited |
Boolean |
No |
No |
|
IsManualDataEntry |
Boolean |
No |
No |
|
DataReference |
String |
Yes |
No |
|
UnitOfMeasure |
String |
Yes |
No |
|
EventFrameTemplate |
String |
No |
No |
|
UnitOfMeasureID |
Guid |
Yes |
No |
|
EventFrameTemplateID |
Guid |
No |
No |
Master.EventFrame.AttributeTemplateCategory
Contains attribute categories related with attribute templates. Because an attribute template can be part of multiple event frame templates (that contain or inherit it, see the AtributeTemplate table), a single association of a category with an attribute template can be represented as multiple relations in this table.
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
TemplateID |
Guid |
No |
Yes |
|
CategoryID |
Guid |
No |
Yes |
|
Template |
String |
No |
No |
|
Category |
String |
No |
No |
Master.EventFrame.EventFrame
Contains event frames.
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
ID |
Guid |
No |
Yes |
|
Name |
String |
No |
No |
|
Description |
String |
Yes |
No |
|
StartTime |
DateTime |
No |
No |
|
EndTime |
DateTime |
Yes |
No |
|
Duration |
TimeSpan |
Yes |
No |
|
Revision |
Int32 |
No |
No |
|
Severity |
String |
No |
No |
|
AreValuesCaptured |
Boolean |
No |
No |
|
IsAnnotated |
Boolean |
No |
No |
|
IsLocked |
Boolean |
No |
No |
|
CanBeAcknowledged |
Boolean |
No |
No |
|
HasReferencedElements |
Boolean |
No |
No |
|
IsRoot |
Boolean |
No |
No |
|
HasChildren |
Boolean |
No |
No |
|
PrimaryReferencedElement |
String |
Yes |
No |
|
Template |
String |
Yes |
No |
|
Parent |
String |
Yes |
No |
|
SecondaryParent |
String |
Yes |
No |
|
Acknowledged |
DateTime |
Yes |
No |
|
AcknowledgedBy |
String |
Yes |
No |
|
Modified |
DateTime |
No |
No |
|
ModifiedBy |
String |
No |
No |
|
PrimaryReferencedElementID |
Guid |
Yes |
No |
|
ParentID |
Guid |
Yes |
No |
|
SecondaryParentID |
Guid |
Yes |
No |
|
TemplateID |
Guid |
Yes |
No |
Master.EventFrame.EventFrameCategory
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
EventFrameID |
Guid |
No |
Yes |
|
CategoryID |
Guid |
No |
Yes |
|
EventFrame |
String |
No |
No |
|
Category |
String |
No |
No |
Master.EventFrame.EventFrameTemplate
Contains event frame templates.
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
ID |
Guid |
No |
Yes |
|
InheritancePath |
String |
No |
No |
|
Name |
String |
No |
No |
|
Level |
UInt8 |
No |
No |
|
Severity |
String |
No |
No |
|
Description |
String |
Yes |
No |
|
CanBeAcknowledged |
Boolean |
No |
No |
|
BaseID |
Guid |
Yes |
No |
Master.EventFrame.EventFrameTemplateCategory
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
TemplateID |
Guid |
No |
Yes |
|
CategoryID |
Guid |
No |
Yes |
|
Template |
String |
No |
No |
|
Category |
String |
No |
No |
Master.EventFrame.FindEventFrames()
Returns the AFEventFrame objects that match the search tokens.
For more information, see the AF SDK Reference page AFEventFrame.FindEventFrames Method.
Parameters
|
Name |
Data type |
|---|---|
|
Query |
String |
Columns
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
ID |
Guid |
No |
Yes |
|
Name |
String |
No |
No |
|
Description |
String |
Yes |
No |
|
StartTime |
DateTime |
No |
No |
|
EndTime |
DateTime |
Yes |
No |
|
Duration |
TimeSpan |
Yes |
No |
|
Revision |
Int32 |
No |
No |
|
Severity |
String |
No |
No |
|
AreValuesCaptured |
Boolean |
No |
No |
|
IsAnnotated |
Boolean |
No |
No |
|
IsLocked |
Boolean |
No |
No |
|
CanBeAcknowledged |
Boolean |
No |
No |
|
HasReferencedElements |
Boolean |
No |
No |
|
IsRoot |
Boolean |
No |
No |
|
HasChildren |
Boolean |
No |
No |
|
PrimaryReferencedElement |
String |
Yes |
No |
|
Template |
String |
Yes |
No |
|
Parent |
String |
Yes |
No |
|
SecondaryParent |
String |
Yes |
No |
|
Acknowledged |
DateTime |
Yes |
No |
|
AcknowledgedBy |
String |
Yes |
No |
|
Modified |
DateTime |
No |
No |
|
ModifiedBy |
String |
No |
No |
|
PrimaryReferencedElementID |
Guid |
Yes |
No |
|
ParentID |
Guid |
Yes |
No |
|
SecondaryParentID |
Guid |
Yes |
No |
|
TemplateID |
Guid |
Yes |
No |
Example:
SELECT Name FROM Master.EventFrame.FindEventFrames(
N'Template:OSIOperation')
Master.EventFrame.GetPlotValues()
Retrieves values over the specified time range suitable for plotting over the number of intervals.
For more information, see the AF SDK Reference page AFData.PlotValues Method.
Parameters
|
Name |
Data type |
|---|---|
|
AttributeID |
Guid |
|
StartTime |
DateTime |
|
EndTime |
DateTime |
|
IntervalCount |
Int32 |
Columns
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
TimeStamp |
DateTime |
No |
No |
|
Value |
Variant |
Yes |
No |
|
Value_Int |
Int64 |
Yes |
No |
|
Value_Double |
Double |
Yes |
No |
|
Value_String |
String |
Yes |
No |
|
Value_DateTime |
DateTime |
Yes |
No |
|
IsValueAnnotated |
Boolean |
No |
No |
|
IsValueGood |
Boolean |
No |
No |
|
IsValueQuestionable |
Boolean |
No |
No |
|
IsValueSubstituted |
Boolean |
No |
No |
|
Error |
String |
Yes |
No |
Master.EventFrame.GetSampledValue()
Returns a sampled value at the specified time.
Parameters
|
Name |
Data type |
|---|---|
|
AttributeID |
Guid |
|
Time |
DateTime |
Columns
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
Value |
Variant |
Yes |
No |
|
Value_Int |
Int64 |
Yes |
No |
|
Value_Double |
Double |
Yes |
No |
|
Value_String |
String |
Yes |
No |
|
Value_DateTime |
DateTime |
Yes |
No |
|
IsValueAnnotated |
Boolean |
No |
No |
|
IsValueGood |
Boolean |
No |
No |
|
IsValueQuestionable |
Boolean |
No |
No |
|
IsValueSubstituted |
Boolean |
No |
No |
|
Error |
String |
Yes |
No |
Example:
SELECT a.Element, a.Name Attribute, sv.Value
FROM Master.Element.Attribute a
CROSS APPLY Master.Element.GetSampledValue(a.ID, 't') sv
WHERE a.Name = 'Fuel Gas Flow'
Master.EventFrame.GetSampledValues()
Returns several sampled values within the specified time range.
Parameters
|
Name |
Data type |
|---|---|
|
AttributeID |
Guid |
|
StartTime |
DateTime |
|
EndTime |
DateTime |
|
TimeStep |
TimePeriod |
Columns
|
Name |
Data type |
Is nullable ? |
Primary key |
|---|---|---|---|
|
TimeStamp |
DateTime |
No |
No |
|
Value |
Variant |
Yes |
No |
|
Value_Int |
Int64 |
Yes |
No |
|
Value_Double |
Double |
Yes |
No |
|
Value_String |
String |
Yes |
No |
|
Value_DateTime |
DateTime |
Yes |
No |
|
IsValueAnnotated |
Boolean |
No |
No |
|
IsValueGood |
Boolean |
No |
No |
|
IsValueQuestionable |
Boolean |
No |
No |
|
IsValueSubstituted |
Boolean |
No |
No |
|
Error |
String |
Yes |
No |
Example:
SELECT a.Element, a.Name Attribute, sv.TimeStamp, sv.Value
FROM Master.Element.Attribute a
CROSS APPLY Master.Element.GetSampledValues(a.ID, 'y', 't', '1h') sv
WHERE a.Name = 'Fuel Gas Flow'
Master.EventFrame.GetSummaries()
Returns several summaries for a single attribute over a time range for each interval within the range.
For more information, see the AF SDK Reference page AFData.Summaries Method.
Parameters
|
Name |
Data type |
|---|---|
|
AttributeID |
Guid |
|
StartTime |
DateTime |
|
EndTime |
DateTime |
|
TimeStep |
TimePeriod |
|
SummaryType |
String |
|
CalculationBasis |
String |
|
TimeType |
String |
For allowed values of the particular [TVF].EventFrame.GetSummaries arguments, see the following AF SDK Reference pages:
-
SummaryType: AFSummaryTypes Enumeration
-
CalculationBasis: AFCalculationBasis Enumeration
-
TimeType: AFTimestampCalculation Enumeration
Columns
Name
Data type
Is nullable ?
Primary key
TimeStamp
DateTime
No
No
Value
Variant
Yes
No
Value_Int
Int64
Yes
No
Value_Double
Double
Yes
No
Value_String
String
Yes
No
Value_DateTime
DateTime
Yes
No
IsValueAnnotated
Boolean
No
No
IsValueGood
Boolean
No
No
IsValueQuestionable
Boolean
No
No
IsValueSubstituted
Boolean
No
No
Error
String
Yes
No
Master.EventFrame.GetSummary()
Returns several summaries for a single attribute over a single time range.
For more information, see the AF SDK Reference page AFData.Summary Method.
Parameters
|
Name |
Data type |
|---|---|
|
AttributeID |
Guid |
|
StartTime |
DateTime |
|
EndTime |
DateTime |
|
SummaryType |
String |
|
CalculationBasis |
String |
|
TimeType |
String |
For allowed values of the particular [TVF].EventFrame.GetSummary arguments, see the following AF SDK Reference pages:
-
SummaryType: AFSummaryTypes Enumeration
-
CalculationBasis: AFCalculationBasis Enumeration
-
TimeType: AFTimestampCalculation Enumeration
Columns
Name
Data type
Is nullable ?
Primary key
TimeStamp
DateTime
No
No
Value
Variant
Yes
No
Value_Int
Int64
Yes
No
Value_Double
Double
Yes
No
Value_String
String
Yes
No
Value_DateTime
DateTime
Yes
No
IsValueAnnotated
Boolean
No
No
IsValueGood
Boolean
No
No
IsValueQuestionable
Boolean
No
No
IsValueSubstituted
Boolean
No
No
Error
String
Yes
No
Master.EventFrame.GetSummary() based on event frame start and end time
Calculates event frame attribute summary based on the event frame start time and event frame end time.
Parameters
|
Name |
Data type |
|---|---|
|
AttributeID |
Guid |
|
SummaryType |
String |
|
CalculationBasis |
String |
|
TimeType |
String |
For allowed values of the particular [TVF].EventFrame.GetSummary arguments, see the following AF SDK Reference pages:
-
SummaryType: AFSummaryTypes Enumeration
-
CalculationBasis: AFCalculationBasis Enumeration
-
TimeType: AFTimestampCalculation Enumeration
Columns
Name
Data type
Is nullable ?
Primary key
TimeStamp
DateTime
No
No
Value
Variant
Yes
No
Value_Int
Int64
Yes
No
Value_Double
Double
Yes
No
Value_String
String
Yes
No
Value_DateTime
DateTime
Yes
No
IsValueAnnotated
Boolean
No
No
IsValueGood
Boolean
No
No
IsValueQuestionable
Boolean
No
No
IsValueSubstituted
Boolean
No
No
Error
String
Yes
No