History with Multiple Scan Classes

Hi Guys,
I would like to keep tag history at a fast rate for a short time (1 second intervals for 1 week), and the same tag at a slower rate for a longer period of time (30 second intervals for 1 year). This will allow detailed analysis of recent events, and still provide the needed information for older data, while not taking up too much hard drive space for the older data.

I’ve had a look at the Tag History Splitter, but it uses the same scan class for both recordings.
I’ve also considered Transaction Groups, but it’s a bit cumbersome to set this up for the number of tags I’m looking at (about 1,000 tags).
Can anybody suggest a good solution?


If you want it to be fully automatic – trending the one pen gives you the appropriate detail – you’ll probably have to record at 1-second intervals all the time, and use a separate background process to prune the week-old data in the database.
Another possibility would be to use transaction groups with wide tables to capture the long-term data. Wide tables generally hold more data with less storage for applications where the recording interval is fixed. For just a thousand tags, you might find the storage requirements for 1-seconds intervals really isn’t that much. (~120 GB for a wide table of DINTs or REALs for a year.)

Thanks pturmel. Great suggestions.
The pruning idea is more attractive as it will automatically apply to any new tags that are historized without having to manually add them to a Transaction Group. And I assume that a trend will still display the recent data as well as the older data even if pruning is done.

I had previously thought about pruning but was worried about how it would affect displaying the trend. Will a trend still display well, even if pruning is done?

You’ll just have to try it. I’ve never done the pruning approach. My customers generally prefer simple storage structures over small storage requirements. Storage is pretty cheap, after all.

Why not just turn on the pre-processed table functionality?

Hi Kyle, not sure what you mean here, could you elaborate?
Or do you mean turn Pre-Processing off, to reduce space?

You could also use the splitter to store into two different schemas - then build out two screens with “long term” and “short term” data retrieval (or switch providers automatically in your charts/trends/whatever else based on date range).

Hi PGriffith, The problem with the splitter is that it uses the same scan class for both records. I want to record the long term data at a slower rate. Cheers.