Table of ContentsIntroduction
Compression methodsTDengine implementationIntroductionIf the original data and decompressed data are exactly the same, the compression method can be considered lossless. A compression method that alters data is considered lossy.
So what do each of these two levels of aggregation mean? We’ll cover this in more detail in the Incremental Computation section. But before that, let’s zoom in and take a look at the exact structure inside Stream Task.
tdengine database PI Connector expands a PI data historian with a modern time series database
Learn MoreThe TDengine PI Connector can integrate your PI Systems with our fully managed TDengine Cloud or with an on-premises deployment of TDengine Enterprise Edition. Contact us at business@tdengine.com and we’ll be happy to architect a solution for tdengine Time Series Database you that makes the most of your data historian.
Scale your system with a powerful hybrid solution: At the same time, with the included TDengine Data Reference, you can continue using PI Vision to view and manipulate all of your data stored in either PI or TDengine. The TDengine PI Connector causes no disruption to your existing workflows and helps you make the best use of your PI System without having to purchase new points.
Losslessly compressed data can be completely reconstructed after decompression into the original raw data. This compression method is used in scenarios where data accuracy is important, such as compressing entire hard drives or compressing executable files. It may also be used for multimedia compression. However, lossless methods have relatively low compression ratios. Common lossless compression methods include differential coding, run-length encoding (RLE), Huffman coding, LZW compression, and arithmetic coding.
On the other hand, with lossy compression, the compressed data cannot be reconstructed into the original data – only into an approximation of that data. This compression method is used in scenarios where data accuracy is not important, such as compressing multimedia files. However, lossy compression enables high compression ratios. Common lossy compression methods include predictive codecs, fractal compression, wavelet compression, JPEG, and MPEG.
Compression methods
Commonly used compression methods for time series data are described as follows:
In the above diagram, the vertical axis represents the wall clock, i.e. the real time. The horizontal axis represents the data arriving in TDengine at the corresponding T1, T2, and T3 times. The blue dots indicate the latest inserted data, and Watermark is the time axis along which to go in the past, subtracting the Watermark time from the last event time to get the time T = latest event time – watermark. All windows with end times earlier than T are closed. These windows are beyond the upper bound of disorder tolerance, and we consider them safe to close without further data insertion.
''' SQL statements '''
'''createDatabase = 'create database if not exists weather'''
createStable = 'CREATE STABLE if not exists weather.pollution (ts TIMESTAMP, pm2
5 FLOAT, pm10 FLOAT,'
createStable += 'so2 FLOAT, no2 FLOAT, co FLOAT, o3 FLOAT,'
createStable += 'temperature FLOAT, pressure FLOAT, dewp FLOAT, rain FLOAT, wind
direction VARCHAR(8),'
createStable += 'windspeed FLOAT) TAGS (station VARCHAR(64))'
Digital Transformation Easier Than Ever
Getting started with TDengine is easier than any other time series database – you can register for a free TDengine Cloud account at cloud.tdengine.com (no credit card required) and see for yourself before making a decision. TDengine Cloud is a fully managed, enterprise-ready cloud solution that saves you time by taking care of database management tasks like clustering, backup, and data retention on its own.
SELECT SPREAD(voltage), SPREAD(current), location FROM test.meters PARTITION BY location;
In addition to these, TDengine also provides functions like STDDEV (standard deviation), MODE (the value with the highest frequency), tdengine Time Series Database and several other useful functions for basic and easy time-series analysis.
The TDengine PI Connector gives you the flexibility you need to grow your business and doesn’t lock you into complicated contracts or expensive licenses. Your new data is stored in TDengine while your existing data remains in PI – and you can still use PI Vision and PI AF to visualize and analyze all your data, no matter which system it’s stored in.
The
Tdengine Database Team is proud to announce the release of TDengine Cloud, a fully managed time series database (TSDB) solution that delivers the industry-leading performance of TDengine 3.0 as a cloud service. This serverless platform can run on Amazon Web Services (AWS), Microsoft Azure, and Google Cloud Platform (GCP) and is offered in free and pay-as-you-go editions.
TDengine suggests to use the globally unique ID of data collection point as a table name (such as device serial number). However, in some scenarios, there is no unique ID, and multiple IDs can be combined into a unique ID. It is not recommended to use a unique ID as tag value.