Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Notifications
Login / Register
Community
Community
Notifications
close
  • Forums
  • Knowledge Center
  • Events & Webinars
  • Ideas
  • Blogs
Help
Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Login / Register
Sustainability
Sustainability

Ask Me About Webinar: Data Center Assets - Modeling, Cooling, and CFD Simulation
Join our 30-minute expert session on July 10, 2025 (9:00 AM & 5:00 PM CET), to explore Digital Twins, cooling simulations, and IT infrastructure modeling. Learn how to boost resiliency and plan power capacity effectively. Register now to secure your spot!

Enabling/Disabling Historic logging using ST

EcoStruxure Geo SCADA Expert Forum

Schneider Electric support forum about installation, configuration, integration and troubleshooting of EcoStruxure Geo SCADA Expert (ClearSCADA, ViewX, WebX).

cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Home
  • Schneider Electric Community
  • Remote Operations
  • EcoStruxure Geo SCADA Expert Forum
  • Enabling/Disabling Historic logging using ST
Options
  • Mark Topic as New
  • Mark Topic as Read
  • Float this Topic for Current User
  • Bookmark
  • Subscribe
  • Mute
  • Printer Friendly Page
Invite a Co-worker
Send a co-worker an invite to the portal.Just enter their email address and we'll connect them to register. After joining, they will belong to the same company.
You have entered an invalid email address. Please re-enter the email address.
This co-worker has already been invited to the Exchange portal. Please invite another co-worker.
Please enter email address
Send Invite Cancel
Invitation Sent
Your invitation was sent.Thanks for sharing Exchange with your co-worker.
Send New Invite Close
Top Experts
User Count
sbeadle
Kirk sbeadle Kirk
309
AndrewScott
Admiral AndrewScott
99
BevanWeiss
Spock BevanWeiss
92
AdamWoodlandToo
Lt. Commander AdamWoodlandToo
38
View All
Related Products
product field
Schneider Electric
EcoStruxure™ Geo SCADA Expert

Invite a Colleague

Found this content useful? Share it with a Colleague!

Invite a Colleague Invite
Back to EcoStruxure Geo SCADA Expert Forum
Anonymous user
Not applicable

Posted: ‎2020-11-24 12:22 PM . Last Modified: ‎2023-05-03 12:07 AM

0 Likes
5
2078
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2020-11-24 12:22 PM . Last Modified: ‎2023-05-03 12:07 AM

Enabling/Disabling Historic logging using ST

Hi 

 

I am trying to control the Historic Logging on tags in CS. For most points I can simply use the OPC point

 

..Point.HistoricLogging

 

However for points like a Trend point I can't do this as its an 'Aggregate' . I have managed to do it to using a script on a mimic but want to call this from an ST program.

 

 


'Enable Trend tags Historic logging
Sub EnableTrendTagHistoricLogging()


Set ObjPoint = Server.FindObject(Server.ThisObject.Parent.FullName + ".RV_FT01_RawPulses")
ObjPoint.Interface.Historic=True

End Sub

'Disable Trend tags Historic logging
Sub DisableTrendTagHistoricLogging()


Set ObjPoint = Server.FindObject(Server.ThisObject.Parent.FullName + ".RV_FT01_RawPulses")
ObjPoint.Interface.Historic=False

End Sub

 

How can I do this?

 

Labels
  • Labels:
  • Logic
  • Scripting
  • Tags:
  • english
  • scada
  • SCADA app
  • SCADA software
  • SCADA tutorial
  • Telemetry and SCADA
Reply

Link copied. Please paste this link to share this article on your social media post.

  • All forum topics
  • Previous Topic
  • Next Topic
Replies 5
AdamWoodland
AdamWoodland Schneider Alumni (Retired)
Schneider Alumni (Retired)

Posted: ‎2020-11-24 02:56 PM

0 Likes
4
2072
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2020-11-24 02:56 PM

You should be able to use Point.Historic.$Enable or Enable$ (I can't remember off the top of my head) as type bool.

 

The problem you'll come across is referencing the properties on the aggregate as they don't existing until the aggregate is enabled. So you can't reference them in the logic if the aggregate is currently disabled and you want to enable it as the logic will bomb out with an error. The other way around the logic will run once to allow you to disable the aggregate but subsequent runs the logic will fail.

 

If you do want to edit the settings on the aggregate beyond enabling it, you'll have to do something tricky and split the function to different logic programs and only call the second logic program once you enable the aggregate. Still becomes a little tricky when the default state is disabled historic as the logic can't be compiled.

 

Have a play and see what works best for your setup.

  • Tags:
  • english
  • scada
  • SCADA app
  • SCADA software
  • SCADA tutorial
  • Telemetry and SCADA
Reply

Link copied. Please paste this link to share this article on your social media post.

BevanWeiss
Spock BevanWeiss
Spock

Posted: ‎2020-11-24 11:38 PM . Last Modified: ‎2020-11-24 11:40 PM

In response to AdamWoodland
0 Likes
1
2056
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2020-11-24 11:38 PM . Last Modified: ‎2020-11-24 11:40 PM

One way to do the Aggregate property update in ST Logic is to use an SQL execution with an UPDATE clause.

It's definitely not the nicest... but it's "robust" against the Aggregate not existing, since then the UPDATE still executes, but there's no WHERE match, so it just doesn't do the UPDATE.

 

Obviously the performance of this is not as good as having a specific reference to the Aggregate property precisely, but it should only ever be a very occasional thing anyway.


Lead Control Systems Engineer for Alliance Automation (VIC).
All opinions are my own and do not represent the opinions or policies of my employer, or of my cat..
  • Tags:
  • english
  • scada
  • SCADA app
  • SCADA software
  • SCADA tutorial
  • Telemetry and SCADA
Reply

Link copied. Please paste this link to share this article on your social media post.

Anonymous user
Not applicable

Posted: ‎2020-11-25 10:45 AM

In response to BevanWeiss
0 Likes
0
2044
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2020-11-25 10:45 AM

We use a PLC pump control systems and RTUs which can be configured remotely via an HMI, CS gets the updated config of what is used onsite so Its not something that I'll be doing often, pretty much initial setup and odd change.. There's quite a few of them in the field though!

 

I'll have a look at the SQL, but I assume I will need to find the tables from the schema and join them etc?

  • Tags:
  • english
  • scada
  • SCADA app
  • SCADA software
  • SCADA tutorial
  • Telemetry and SCADA
Reply

Link copied. Please paste this link to share this article on your social media post.

Anonymous user
Not applicable

Posted: ‎2020-11-25 10:47 AM

In response to AdamWoodland
0 Likes
1
2043
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2020-11-25 10:47 AM

Hi Adam

 

I tried the $enable, which compiled but nothing seemed to happen the enable$ didn't compile... I am wondering if the SQL method would be better as they won't change often?

  • Tags:
  • english
  • scada
  • SCADA app
  • SCADA software
  • SCADA tutorial
  • Telemetry and SCADA
Reply

Link copied. Please paste this link to share this article on your social media post.

BevanWeiss
Spock BevanWeiss
Spock

Posted: ‎2020-11-25 07:14 PM

In response to Anonymous user
0 Likes
0
2038
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2020-11-25 07:14 PM

It's a little tricky still...

 

So with your Logic you can use something like

 

PROGRAM HistoricEnableProgram

  VAR_INPUT

    Enable : BOOL;

  END_VAR

 

  VAR

    HistoricEnabled AT %M(PointPath.Historic.$Enabled) : BOOL;

  VAR_END

 

  HIstoricEnabled := Enable;

END_PROGRAM

 

That will let you Enable / Disable the Historic Aggregate.

This is then where the ST SQL comes in... if you want to change things on the Historic Aggregate, you can't just reference the OPC property, since when the Aggregate is disabled, the OPC properties simply do not exist, and hence the logic won't compile.

 

So the options are:

1. Use another ST Logic Routine which takes the FullName as an indirect to allow you to manipulate values...

2. Use ST SQL queries

 

The first is probably the better option.  It's more understandable, and less costly in performance.  And... even better.  The help has some help on this.

Core Reference > Coding > Logic > Checking that Aggregates are Enabled in Logic Programs

 

You'll need to combine what I've put above with your learnings from the help document, and then you should have the whole solution.

 

 

 

 


Lead Control Systems Engineer for Alliance Automation (VIC).
All opinions are my own and do not represent the opinions or policies of my employer, or of my cat..
  • Tags:
  • english
  • scada
  • SCADA app
  • SCADA software
  • SCADA tutorial
  • Telemetry and SCADA
Reply

Link copied. Please paste this link to share this article on your social media post.

Preview Exit Preview

never-displayed

You must be signed in to add attachments

never-displayed

 
To The Top!

Forums

  • APC UPS Data Center Backup Solutions
  • EcoStruxure IT
  • EcoStruxure Geo SCADA Expert
  • Metering & Power Quality
  • Schneider Electric Wiser

Knowledge Center

Events & webinars

Ideas

Blogs

Get Started

  • Ask the Community
  • Community Guidelines
  • Community User Guide
  • How-To & Best Practice
  • Experts Leaderboard
  • Contact Support
Brand-Logo
Subscribing is a smart move!
You can subscribe to this board after you log in or create your free account.
Forum-Icon

Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.

Register today for FREE

Register Now

Already have an account? Login

Terms & Conditions Privacy Notice Change your Cookie Settings © 2025 Schneider Electric

This is a heading

With achievable small steps, users progress and continually feel satisfaction in task accomplishment.

Usetiful Onboarding Checklist remembers the progress of every user, allowing them to take bite-sized journeys and continue where they left.

of