• Download
  • Products
    • Product Highlights
      • DataHub Smart MQTT Broker
      • DataHub IoT Gateway
      • DataHub OPC Gateway
      • DataHub service for Azure
      • DataHub OPC Bridge
      • OPC DataHub
      • DataHub WebView
      • DataHub Modbus OPC Server
    • Tunnellers
      • DataHub UA Tunneller
      • DataHub DA Tunneller
      • DataHub Tunnel A&E
      • DataHub Modbus Tunneller
      • DataHub DDE Tunneller
      • Individual Features
        • Redundancy
        • Data Diode Mode
        • Monitoring
    • Historians
      • Connect to InfluxDB
      • Connect to Amazon Kinesis
      • Connect to AVEVA Historian
      • Connect to AVEVA Insight
      • Connect to AVEVA PI
      • Connect to RESTful Systems
      • Connect to Kafka
      • Connect to ODBC
      • Connect to Azure Event Hubs
      • Connect to OPC Classic HDA
    • Notifications
      • Alarm and Notification
      • Email / SMS
      • OPC A&E support
      • OPC UA A&C support
    • Excel and DDE
      • DataHub Add-In
        for Microsoft Excel
      • DDE / Excel
    • Loggers
      • DataHub OPC Logger
      • DataHub Modbus Logger
  • Purchasing
    • How to Purchase
    • Request a Quote
    • Feature Matrix
    • Software Subscription Plan
    • Maintenance Support Plan
    • Educational Program
  • Learning Hub
    • Industries & Use Cases
      • Wind & Solar
      • Conventional Energy
      • Oil & Gas
      • Minerals & Mining
      • Manufacturing
      • Food & Beverage
      • Pharma & Healthcare
      • System Integration
      • Machines & Tools
    • Knowledge Center
      • Videos
      • Webinars
      • How-To
      • Case Studies
      • White Papers
      • Essential Guides
        • MQTT & Sparkplug Essentials
        • DataHub Security Essentials
    • Connecting
      • Industrial AI
      • Industrial IoT
      • Secure OT to IT
      • OPC
      • Historian
      • MQTT
        • Sparkplug
      • Database
      • Modbus
      • Excel
      • Web
      • Embedded
      • Open APIs
      • DHTP
      • Architecture
  • Support
    • FAQ
    • Documentation
    • Release Notes
    • Technical Specifications
  • About
    • Partners
    • Customers
    • Testimonials
    • Privacy Policy
    • Terms of Use
    • Legal Notices
  • Click to open the search input field Click to open the search input field Search
  • Menu Menu
  • Download
  • Products
    • DataHub Smart MQTT Broker
    • DataHub IoT Gateway
    • DataHub OPC Gateway
    • DataHub service for Azure
    • DataHub OPC Bridge
    • OPC DataHub
    • DataHub WebView
    • DataHub Modbus OPC Server
    • Tunnellers
      • DataHub UA Tunneller
      • DataHub DA Tunneller
      • Tunnel A&E
      • DataHub Modbus Tunneller
      • DataHub DDE Tunneller
    • Historians
      • Connect to InfluxDB
      • Connect to Amazon Kinesis
      • Connect to AVEVA Historian
      • Connect to AVEVA Insight
      • Connect to AVEVA PI
      • Connect to RESTful Systems
      • Connect to Kafka
      • Connect to Azure Event Hubs
      • Connect to ODBC
      • Connect to OPC Classic HDA
    • Notifications
      • Alarm and Notification
      • Email / SMS
      • OPC A&E support
      • OPC UA A&C support
    • Excel and DDE
      • DataHub Add-in for Microsoft Excel
      • DDE / Excel
    • Loggers
      • DataHub OPC Logger
      • DataHub Modbus Logger
      • Monitoring
    • Individual Features
      • Redundancy
      • Data Diode Mode
      • Monitoring
  • Purchasing
    • How to Purchase
    • Request a Quote
    • Feature Matrix
    • Software Subscription Plan
    • Maintenance Support Plan
    • Educational Program
  • Learning Hub
    • Industries & Use Cases
      • Wind and Solar
      • Conventional Energy
      • Oil & Gas
      • Minerals & Mining
      • Manufacturing
      • Food and Beverage
      • Pharma and Healthcare
      • System Integration
      • Machines and Tools
    • Knowledge Center
      • Videos
      • Webinars
      • How-to
      • Case Studies
      • White Papers
    • Essential Guides
      • MQTT and Sparkplug Essentials
      • DataHub Security Essentials
    • Connecting
      • Industrial AI
      • Industrial IoT
      • Secure OT to IT
      • OPC
      • Historian
      • MQTT
        • Sparkplug
      • Database
      • Modbus
      • Excel
      • Web
      • Embedded
      • Open APIs
      • DHTP
      • Architecture
  • Support
    • FAQ
    • Documentation
    • Release Notes
    • Technical Specifications
  • About
    • Partners
    • Customers
    • Testimonials
    • Privacy Policy
    • Terms of Use
    • Legal Notices

How to store and access time-series data with an ODBC database

No access to YouTube? Click here to view locally

Summary

  1. Make sure you have an ODBC-compliant database accessible with a system DSN.
  2. Download and install Cogent DataHub software.
  3. Start the DataHub.
  4. Configure the connection to your database.

For more details and options, see the documentation.

DataHub product used: ODBC Historian

Transcript

  1. How to store and access time-series data with an ODBC database.
  2. To make this connection, you will need an ODBC-compliant database installed on your network that you can access with a system DSN.  Please see the documentation for details.
  3. First, download and install Cogent DataHub software.
  4. Start the DataHub, and from the Properties window, select the External Historian option, and press the Add button.
  5. Select the Historian Type ODBC.
  6. In Connection Settings, create a label for this connection.
  7. Enter the label of the system DSN for the database you are connecting to.
  8. If the database uses Windows Authentication, leave the username and password fields empty.
  9. Or, if the database uses legacy authentication, enter the legacy username and password. Leave the other options at the default settings.
  10. In Tables and Columns, enter the name of the database table that will receive the data.
  11. Then enter the names of the columns from the table for point name, value, quality and timestamp.
  12. For the row index, enter the name of the index column from the table, which is typically the row number.
  13. Then select the datatype used by the index column.
  14. Now we will use the script editor to generate Insert and Query Statements for the database, with example templates. Click the three dots button to open the ASP document editor.
  15. From the Templates list, click on the plus ( + ) symbol to add the template for your database. This will populate the script fields with the correct entries.
  16. Click “Yes” on the dialog box to overwrite all nine script properties.
  17. After installing a template, the script editor window will contain the working script associated with each field listed on the left.  Click OK to save your changes.
  18. The Insert and Query entries are now filled in.
  19. Leave Modify Point Names, Data Sampling and Forwarding at the defaults for now.
  20. Select the datapoints to be recorded by the historian.  We are using DataPid data in this demo.
  21. Click the OK button to close the dialog, and the Apply button in the Properties window to save your configuration. Now you are recording your data.
  22. To access your data from the database, you can make the ODBC historian a historical data source.  Select its label in “Read values from this historian”, and click the Apply button.
  23. You can use Quicktrend to view the data history. In the Properties window, select Quicktrend, then click the Open Quicktrend button.
  24. Select your points and Quicktrend will display their history. The data is also available for store-and-forward and other applications.
  25. This is how to store, access, and display time-series data with an ODBC database, using DataHub software.

Background

ODBC (Open Database Connectivity) specifies a standardized, common interface that is available from almost every database vendor, including SQL Server, MS Access, MySQL, Oracle, and many more. The DataHub External Historian feature has an option for connecting to and exchanging data with any database that supports ODBC connections.

Connecting Cogent DataHub software to an ODBC database is a good way to store DataHub data from supported protocols like OPC DA and UA, OPC A&E and A&C, MQTT, Modbus, ODBC, and more, and to access data that has been stored. This feature is often used in store and forwarding scenarios.

Skkynet provides Cogent DataHub secure-by-design software and services to let you acquire, aggregate, monitor, control visualize, and network live process data in-plant or over insecure external networks, making it ideal for OT to IT and cloud connections. You can isolate control networks from cyber attacks and integrate industrial data under a unified namespace, all without compromising the plant.

Cogent DataHub products wheel diagram

How-to Videos


Basic Connections:

Connect to an OPC UA server
Connect to an OPC DA server
Connect an OPC UA client
Connect an OPC DA client
Connect an MQTT client
Connect to an MQTT broker

Protocol Conversions:

Convert OPC DA to OPC UA
Convert OPC UA to OPC DA
Convert OPC DA to MQTT
Convert OPC UA to MQTT
Convert MQTT to OPC DA
Convert MQTT to OPC UA

Tunnelling:

Tunnel OPC UA – outbound
Tunnel OPC DA – outbound
Tunnel OPC DA – inbound

Advanced:

Use a DataHub script
Configure Redundancy
Connect time-series data to ODBC

Connect through a Data Diode:

Connect OPC UA thru Data Diode
Connect OPC DA thru Data Diode
Connect MQTT thru Data Diode to Client
Connect MQTT thru Data Diode to Cloud

Connect through a DMZ:

Connect OPC UA thru DMZ
Connect OPC DA thru DMZ
Connect MQTT thru DMZ
Cogent DataHub footer logo white
  • Download
  • Products
  • Purchasing
  • Learning Hub
  • Support
  • About
  • Back to Top
  • LinkedIn iconTwitter iconYouTube icon

Skkynet
302-2233 Argentia Road
Mississauga, ON L5N 2X7

International: 1-905-702-7851
US toll free: 1-888-702-7851

[email protected]
[email protected]
[email protected]
[email protected]

© 2026 Skkynet | All rights reserved | Legal notices
Scroll to top Scroll to top Scroll to top

We are using cookies to give you the best experience on our website.

You can find out more about which cookies we are using or switch them off in .

Cogent DataHub Logo
Powered by  GDPR Cookie Compliance
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.

Strictly Necessary Cookies

Strictly Necessary Cookie should be enabled at all times so that we can save your preferences for cookie settings.

3rd Party Cookies

This website uses Google Analytics to collect anonymous information such as the number of visitors to the site, and the most popular pages.

Keeping this cookie enabled helps us to improve our website.

Cookie Policy

More information about our Cookie Policy