Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Logging Historical Data with the Citadel Database (DSC Module)

The National Instruments Citadel historical database is a database that the LabVIEW Datalogging and Supervisory Control (DSC) Module and other National Instruments products use. This database efficiently stores data that applications acquire and process. The DSC Module uses the Citadel historical database to log shared variable data from the Shared Variable Engine. The DSC Module also includes the Citadel ODBC driver, which contains special commands to perform data transforms, so you can retrieve, manipulate, and analyze historical data automatically from outside the LabVIEW environment.

Note  If you have applications that use the Classic Historical Trend Viewer (HTV) from a previous version of the DSC Module, you still can use the HTV in the previous applications. Do not use the HTV in new applications with the DSC Module 8.x.

Data processed by the Shared Variable Engine is contained in memory; LabVIEW does not create a file to hold the data. When you run an application configured to log data, LabVIEW logs data from the Shared Variable Engine to the Citadel historical database. You cannot log data when the Shared Variable Engine is stopped.

The Citadel historical database includes an ODBC driver, which enables other applications to directly retrieve data from a Citadel database using SQL queries. The Citadel 5 ODBC driver is compliant with SQL 92 and ODBC 2.5 standards. All clients that follow these standards can retrieve data from a Citadel 5 database. ADO clients can use the ODBC driver through the Microsoft OLE DB Provider for ODBC Drivers to access the Citadel 5 database. MS Query wizard can be used to build-up queries. The Citadel database runs on the Windows computer as a service.

The maximum size for alarm and event data in a Citadel database is 2 GB. You can upgrade to the full version of SQL Server 2000 to remove the size limit for alarm and event data. There is no size limit for historical data.

Caution  Do not stop Citadel database services while the DSC Module or the Shared Variable Engine is running. If you stop these services, you cannot log or retrieve data or alarms.

The data you log to a Citadel database resides in a set of files in the target directory you set for logging. This data can include shared variable values from the application as well as alarms and events. You determine the data that is logged to a specific location when you configure shared variables and alarm and event logging for shared variables. You can log data to the local computer or to a remote computer on the network, but the directory to which you want to log must be writable from the computer running the Shared Variable Engine.

You can access Citadel data through the Historical Data Viewer, Historical VIs, SQL queries, or any other ODBC-compliant application such as Microsoft Query, Microsoft Access, or Microsoft Excel.


Resources


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit