What's New in PI AF 2018 SP2
- Last UpdatedNov 18, 2025
- 5 minute read
- PI System
- AF SDK 2024 R2
- Developer
The PI AF 2018 SP2 (2.10.5) release adds the ability to support the OR operator in search queries along with additional performance and usability improvements in many areas.
Other major enhancements include:
- Ability to import analyses/notifications in disabled stated enabling easier management when moving analyses/notifications between different machines.
- Support for base template only templates for easier management of templates.
- Ability to set a default PI Data Archive per PI System or AF Database enabling easier management of AF databases between machines.
- Expose PI Analysis Service runtime status and basic information via the SDK.
This topic contains the following sections:
OSIsoft.AF Namespace
The PISystemDefaultPIServerName and AFDatabaseDefaultPIServerName properties have been added to deterministically resolve the %SERVER% substitution pattern in configuration string based upon this setting.
The new DisableNewAnalysesAndNotifications import option allows new analyses and notifications created by the import to be created in the disabled state. This option will also ignore the specified status values in the import file for existing analyses and notifications, their status values will not be affected by the import.
OSIsoft.AF.Analysis Namespace
The AFAnalysisServiceQueryRuntimeInformation methods have been added to query the analysis service for runtime information. This will return a list of AFAnalysisServiceRuntimeFieldValue values. The RuntimeInformationFields property returns a list of runtime information fields that can be queried and filtered on.
The DeleteExistingDataCalculateDependents queued calculation mode has been added to also queue recalculation of all the dependent analyses.
OSIsoft.AF.Asset Namespace
You can now specify that objects cannot be created from a base template by setting the AFElementTemplateBaseTemplateOnly property to true. This allows a base template to be defined with basic common attributes that you don't want any objects to be created directly from it and force objects to be created from one of the derived templates.
The AFAttributeGetPaths(String) method has been added to return all the paths to an attribute.
The AFAttributeTraitAllowDisplayDigits property indicates if display digits are allowed to be specified for an attribute trait. The HealthScore and Location traits have this property set and allow display digits to be set independently from their parent attribute.
The AFSystemStateCodeFutureDataUnsupported system state code has been added.
OSIsoft.AF.Data Namespace
The AFDataCacheIsSuspendedSignupEnabled and AFDataPipeIsSuspendedSignupEnabled properties have been added to allow items to be added to the data cache or pipe in a suspended state and will periodically retry to establish communication to the server for the suspended items. Suspended sign ups will report an AFDataPipeSignupSuspendedException exception when added. The first events for a suspended item after establishing sign up will be a special AFDataPipeSignupEstablishedEvent type.
OSIsoft.AF.Diagnostics Namespace
Several changes have been added to improve manageability:
- The new AFAdmin class has been added which exposes administration functions that were previously only available using the AFDiag utility. This allows these maintenance functions to be performed using an application or PowerShell.
- The number of RPC retries are now returned from the server with the new AFRpcMetricRetryCount property.
- The PISystemGetSessions(NullableAFTime, NullableAFTime, AFSessionSortField, AFSortOrder, Int32, Int32) overload method along with the AFSessionSortField enumeration have been added to allow paging through the session information of the server connections.
OSIsoft.AF.EventFrame Namespace
A new AFEventFrameGetPaths method has been added to return all the paths to an event frame.
OSIsoft.AF.PI Namespace
The statistics for the data pipe can be obtained using the PIDataPipeDataPipeStatistics property.
OSIsoft.AF.Search Namespace
Search queries now support OR conditions. A new generic AFSearchT base class has been added to implement many of the common properties and methods in each of the derived search classes. As part of this change, several methods have been marked as obsolete to encourage the use of the new methods. For example, the IAFSearchTFindObjects in the generic class should be preferred over the Find method in the derived search class.
The AFSearchTokenBase class, the AFSearchTokenCollection class, along with the following derived classes should be used instead of the old AFSearchToken structure which does not support OR conditions:
- AFSearchExpressionToken class.
- AFSearchFilterToken class.
- AFSearchQueryToken class.
- AFSearchValueToken class.
The following properties, methods, and constructors have been added to support the use of the AFSearchTokenBase base class for search tokens:
- AFSearchTokenCollection property.
- AFSearchParseQueryString(String) method.
- AFAnalysisSearchAFAnalysisSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFAnalysisTemplateSearchAFAnalysisTemplateSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFAttributeSearchAFAttributeSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFCaseSearchAFCaseSearch(AFDatabase, String, AFSearchMode, AFTime, AFTime, IListAFSearchTokenBase) constructor.
- AFCaseSearchAFCaseSearch(AFDatabase, String, AFEventFrameSearchMode, AFTime, IListAFSearchTokenBase) constructor.
- AFCaseSearchAFCaseSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFElementSearchAFElementSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFEventFrameSearchAFEventFrameSearch(AFDatabase, String, AFSearchMode, AFTime, AFTime, IListAFSearchTokenBase) constructor.
- AFEventFrameSearchAFEventFrameSearch(AFDatabase, String, AFEventFrameSearchMode, AFTime, IListAFSearchTokenBase) constructor.
- AFEventFrameSearchAFEventFrameSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFNotificationContactTemplateSearchAFNotificationContactTemplateSearch(PISystem, String, IListAFSearchTokenBase) constructor.
- AFNotificationRuleSearchAFNotificationRuleSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFNotificationRuleTemplateSearchAFNotificationRuleTemplateSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
- AFTransferSearchAFTransferSearch(AFDatabase, String, AFSearchMode, AFTime, AFTime, IListAFSearchTokenBase) constructor.
- AFTransferSearchAFTransferSearch(AFDatabase, String, AFEventFrameSearchMode, AFTime, IListAFSearchTokenBase) constructor.
- AFTransferSearchAFTransferSearch(AFDatabase, String, IListAFSearchTokenBase) constructor.
OSIsoft.AF.Time Namespace
The following additional properties were exposed on the AFTimeSpan class: