Accessing Databases Using OPC

  • February 04, 2013
  • News
In any industry, databases are the foundation of many automation applications.  Databases are consistently used as a gateway to interface with the outside world, whether to a process optimization application, Computer Maintenance Management System (CMMS), composition analyzer, or a custom, in-house application.  OLE for Process Control (OPC) has become the standard used by applications to poll devices for real-time data.  This widespread industry acceptance has made it necessary for many organizations to convert archived data to real-time data and vice-versa.  Some access methods already exist today, such as ODBC; however these methods are intended for relational data, rather than real-time transfers.  To further complicate issues, products from Sybase, Oracle, and Microsoft all have their own Application Programming Interfaces (APIs) that are used to optimize operations.  OPC can take advantage of real-time values from what once was a relational database by using Generic Database Access (GDA) technology.  This technology continues to reinforce why industry is turning to OPC as their connectivity standard.
What is OPC?
OPC standardizes the way that plant floor devices such as PLCs, DCSs, and analyzers share data with software applications such as HMIs, Process Historians, and Trenders.  Regardless of the type of device, data is always shared in the same standardized format.  Of course, OPC deals with one side of the interface. A database might reside on the other side, and so the communication must be properly managed.
OPC Generic Database Access (GDA)
OPC GDA technology deals with the translation of data from databases to standardized OPC values and back again.  GDA can connect an application to any database, regardless of the table structure — even a poorly configured database.  GDA is built with an OPC front end, and can therefore be effectively used to provide a host of database connectivity solutions.  For example, OPC applications such as Human/Machine Interfaces (HMI), expert systems, and archivers/historians can easily use their existing OPC interfaces to quickly integrate a database as a real-time data source.  In addition, since OPC GDA technology also enables a database to be used to store new information,  GDA can be used to collect data from an OPC source and archive it in the database, such as the case in a CMMS.
Different Table Structures: No Problem
Databases from different vendors and programmers are likely to have different table structures. GDA enables the user to configure queries to access any structure imagined; a simple structure requires a simpler query. 
GDA is supercharged when it is coupled with OPC.  Because OPC for GDA standardizes the data access method, every point is guaranteed to have three attributes: a value, quality and timestamp, just like data from any other OPC source.  It is irrelevant to OPC whether the application connects to a DCS, PLC, database, or other device, because the interface is always the same.
OPC Servers Run Efficiently
OPC GDA enables applications to interpret relational data as real-time data, and vice-versa.  Databases are slow, and therefore data throughput bottlenecks often occur.  Since OPC communication easily outperforms any GDA connection, adding an OPC server to the system will not add to a performance bottleneck. The OPC server can easily keep up with any database changes.
Generic Database Access enhances OPC’s universal connectivity
To summarize, OPC for GDA enables applications to use any database as if it was a standard OPC data source.  The interface remains consistent, whether inserting data in a database, or retrieving data for viewing, supervising, or analysis purposes. 
This article was written by Randy Kondor, OPC Product Manager at Matrikon. Randy is responsible for Matrikon’s OPC business unit which is comprised of over 50 full time employees. Since 1996, Randy has been vastly involved within the OPC industry and a strong supporter of the OPC Foundation. He continues to dedicate himself to spreading the OPC Foundation's message about system interoperability and inter-vendor cooperation. Randy has been instrumental in the vision, development, and distribution of several OPC products such as OPC Data Manager, OPC Redundancy Broker and OPC Genie. As of late, Randy has been the key driving force behind OPC Tunnelling technology - a new emerging trend.
MatrikonOPC is a charter member of the OPC Foundation and the world's largest developer of OPC servers, client, tools and utilities, with a collection of over 500 interfaces. Boasting more than 30,000 users and over 100,000 installations around the world, MatrikonOPC provides connectivity to every major control system and application on the market. These products and solutions are the culmination of Matrikon's experience since 1988 in the design and implementation of device-specific communication drivers. Our vendor interoperability and OPC compliance are guaranteed which helps make us the global leader in industrial connectivity.
Additional Resources:
OPC Tutorial:
Matrikon OPC:

Did you enjoy this great article?

Check out our free e-newsletters to read more great articles..