Skip to main content
PI System
Asset Framework
Data Integration

Querying AF Data Using PI OLEDB Provider 4.0: Beta Release and New Capabilities

The PI OLEDB Provider 4.0 now supports SQL queries against PI Asset Framework (AF), making it easier to integrate AF data with your tools. The beta is available for vCampus subscribers.

Roshan Soni

3 min read

Querying Asset Framework (AF) Data with PI OLEDB Provider 4.0: What You Need to Know

OSIsoft's PI OLEDB Provider has taken a major step forward—version 4.0 now supports querying data directly from the PI Asset Framework (AF)! For engineers and developers working with the PI System, this opens up convenient new possibilities for accessing AF data using familiar SQL-based tools and techniques.

What Is PI OLEDB Provider?

PI OLEDB Provider is an interface that allows users to query and update PI System data using SQL syntax. It's widely used for integration with reporting tools, custom applications, and other databases. Traditionally, it focused on data from the PI Data Archive.

What Does AF Support Bring?

With the release of version 4.0, you can now directly query asset and metadata stored in PI Asset Framework (AF), not just time-series data from the PI Data Archive. This means:

  • Access to AF Elements and attributes via SQL queries
  • New capabilities to join data across the PI Data Archive and AF within a single query
  • Easier integration of AF-based organizational structures and reference data into custom reports and business solutions

Example Use Cases

  • Business Intelligence (BI): Pull asset hierarchies and metadata into your BI tools using SQL.
  • Custom Integrations: Join process data with asset context for more meaningful analytics.
  • Ad Hoc Reporting: Enable end users to leverage familiar SQL queries against AF data for rapid insight.

Getting Started With the Beta

As of the initial public beta, this functionality is available to vCampus (now PI Square) subscribers. Interested users should:

  1. Download the latest beta release from the OSIsoft PI Square (vCampus) forums
  2. Install the PI OLEDB Provider 4.0 on a test environment
  3. Review updated documentation for new tables and query patterns supporting AF
  4. Try sample queries to retrieve AF elements and attributes

Example Query

Here is a simple example to list all elements in a given AF Database:

SELECT * FROM [AFElement] WHERE [DatabaseName] = 'My_AF_Database'

Things to Watch For

  • As this is a beta, not all AF features may be supported yet—refer to the release notes
  • Performance best practices will continue to evolve as the provider matures
  • Provide feedback! Community input is vital for a successful full release

Conclusion

Version 4.0 of PI OLEDB Provider marks an exciting evolution for PI System data access. With AF support, you can unlock new ways to leverage the power of asset context in your data integrations and analytics.

Happy coding, and don’t forget to share your feedback with the PI community!

Tags

#Asset Framework
#AFSDK
#Data Integration
#SQL Queries
#PI OLEDB
#PI System Beta

About Roshan Soni

Expert in PI System implementation, industrial automation, and data management. Passionate about helping organizations maximize the value of their process data through innovative solutions and best practices.

Sign in to comment

Join the conversation by signing in to your account.

Comments (0)

No comments yet

Be the first to share your thoughts on this article.

Related Articles

Enhancing PI ProcessBook Trends with Banding and Zones: User Needs, Workarounds, and the Road Ahead

A look at the user demand for trend banding/zoning in OSIsoft PI ProcessBook, current VBA workarounds, UI challenges, and how future PI Vision releases aim to address these visualization needs.

Roshan Soni

Migrating PIAdvCalcFilVal Uptime Calculations from PI DataLink to PI OLEDB

Learn how to translate PI DataLink's PIAdvCalcFilVal advanced calculations—like counting uptime based on conditions—into efficient PI OLEDB SQL queries. Explore three practical approaches using PIAVG, PIINTERP, and PICOunt tables, and get tips for validation and accuracy.

Roshan Soni

Understanding PI Web API WebID Encoding: Can You Generate WebIDs Client-Side?

Curious about how PI Web API generates WebIDs and whether you can encode them client-side using GUIDs or paths? This article explores the encoding mechanisms, current documentation, and best practices for handling WebIDs in your applications.

Roshan Soni