Sign In Help
Schneider Electric
HelpSign In
Schneider Electric Exchange
  • Home
  • Collaborate
  • Develop
  • Shop
Home Collaborate Develop Shop Log in or Register Help

Invite a Co-worker

Send a co-worker an invite to the Exchange 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
  • Home
  • Collaborate
  • Exchange Community
  • :
  • SCADA & Telemetry Solutions
  • :
  • Geo SCADA Expert Forum
  • :
  • Re: [Imported] Search Keys -- Good or Bad?
Community Menu
  • Forums
    • By Topic
        • EcoStruxure IT
          • EcoStruxure IT forum
        • Industrial Automation
          • Industry Automation and Control Forum
          • Alliance System Integrators Forum
          • Machine Solutions in the Digital Transformation
          • EcoStruxure Automation Expert / IEC 61499 Forum
          • Industrial Edge Computing Forum
          • Level and Pressure Instrumentation Forum
          • Modicon User Group
          • PLC Club Indonesia
          • SEE Automation Club Forum
          • Fabrika ve Makina Otomasyonu Çözümleri
          • Форум по промышленной автоматизации СНГ
        • SCADA & Telemetry Solutions
          • Geo SCADA Expert Forum
          • SCADA and Telemetry Devices Forum
        • Power Distribution IEC
          • Power Distribution and Digital
          • Power Standards & Regulations
          • Paneelbouw & Energie Distributie
        • Power Distribution Softwares
          • EcoStruxure Power Design Forum
          • SEE Electrical Building+ Forum
          • LayoutFAST User Group Forum
        • Solutions for your Business
          • Solutions for Food & Beverage Forum
          • Solutions for Healthcare Forum
    • By Segment
        • Food & Beverage
          • Solutions for Food & Beverage Forum
        • Healthcare
          • Solutions for Healthcare Forum
      • EcoStruxure IT
        • EcoStruxure IT forum
      • Industrial Automation
        • Industry Automation and Control Forum
        • Alliance System Integrators Forum
        • Machine Solutions in the Digital Transformation
        • EcoStruxure Automation Expert / IEC 61499 Forum
        • Industrial Edge Computing Forum
        • Level and Pressure Instrumentation Forum
        • Modicon User Group
        • PLC Club Indonesia
        • SEE Automation Club Forum
        • Fabrika ve Makina Otomasyonu Çözümleri
        • Форум по промышленной автоматизации СНГ
      • SCADA & Telemetry Solutions
        • Geo SCADA Expert Forum
        • SCADA and Telemetry Devices Forum
      • Power Distribution IEC
        • Power Distribution and Digital
        • Power Standards & Regulations
        • Paneelbouw & Energie Distributie
      • Power Distribution Softwares
        • EcoStruxure Power Design Forum
        • SEE Electrical Building+ Forum
        • LayoutFAST User Group Forum
      • Solutions for your Business
        • Solutions for Food & Beverage Forum
        • Solutions for Healthcare Forum
      • Food & Beverage
        • Solutions for Food & Beverage Forum
      • Healthcare
        • Solutions for Healthcare Forum
  • Blogs
    • By Topic
        • Industrial Automation
          • Industrial Edge Computing Blog
          • Industry 4.0 Blog
          • Industrie du Futur France
        • SCADA & Telemetry Solutions
          • SCADA and Telemetry Blog
        • Power Distribution IEC
          • Power Events & Webinars
          • Power Foundations Blog
        • Power Distribution NEMA
          • NEMA Power Foundations Blog
        • Power Distribution Softwares
          • EcoStruxure Power Design Blog
          • SEE Electrical Building+ Blog
        • Solutions for your Business
          • Solutions for Food & Beverage Blog
          • Solutions for Healthcare Blog
          • Solutions for Retail Blog
        • Community experts & publishers
          • Publishers Community
    • By Segment
        • Food & Beverage
          • Solutions for Food & Beverage Blog
        • Healthcare
          • Solutions for Healthcare Blog
        • Retail
          • Solutions for Retail Blog
      • Industrial Automation
        • Industrial Edge Computing Blog
        • Industry 4.0 Blog
        • Industrie du Futur France
      • SCADA & Telemetry Solutions
        • SCADA and Telemetry Blog
      • Power Distribution IEC
        • Power Events & Webinars
        • Power Foundations Blog
      • Power Distribution NEMA
        • NEMA Power Foundations Blog
      • Power Distribution Softwares
        • EcoStruxure Power Design Blog
        • SEE Electrical Building+ Blog
      • Solutions for your Business
        • Solutions for Food & Beverage Blog
        • Solutions for Healthcare Blog
        • Solutions for Retail Blog
      • Community experts & publishers
        • Publishers Community
      • Food & Beverage
        • Solutions for Food & Beverage Blog
      • Healthcare
        • Solutions for Healthcare Blog
      • Retail
        • Solutions for Retail Blog
  • Ideas
        • Industrial Automation
          • Modicon Ideas & new features
        • SCADA & Telemetry Solutions
          • Geo SCADA Expert Ideas
          • SCADA and Telemetry Devices Ideas
  • Knowledge Center
    • Building Automation Knowledge Base
    • Industrial Automation How-to videos
    • Ask Exchange
    • Digital E-books
    • Success Stories Corner
    • Power Talks
  • Events & Webinars
  • Support
    • User Guide
    • Leaderboard
    • Releases Notes
How can we help?
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: 
49472members
Join Now
242767posts
Join Now

[Imported] Search Keys -- Good or Bad?

Options
  • Subscribe to RSS Feed
  • Mark Topic as New
  • Mark Topic as Read
  • Float this Topic for Current User
  • Bookmark
  • Subscribe
  • Mute
  • Printer Friendly Page
Solved Go to Solution
Back to Geo SCADA Expert Forum
Solved
sbeadle
Sisko sbeadle Sisko
Sisko
‎2019-11-26 02:04 PM
0 Likes
1
271
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content
‎2019-11-26 02:04 PM

[Imported] Search Keys -- Good or Bad?

>>Message imported from previous forum - Category:ClearSCADA Software<<
User: tfranklin, originally posted: 2019-09-30 16:26:51 Id:528
I'm looking to start some discussion on the topic of Search Keys. They seem really beneficial when used properly. That said, we've never really used them in the past so my exposure to them is fairly limited. From what I can tell, a search key is a new metadata field that acts (when Tag is checked) a value map. Search keys are required to be unique if Tag is checked, so I'm going to assume they're indexed. With tag checked, you get some new liberties with expressions where instead of full path you can use searchkeyhere.propertyhere. Pretty neat stuff.

For those who have insights into Search Keys, I ask the following:

1. What're the negative impacts of search keys? Ex: Are they treated like indirect animations where they should really be avoided unless used wisely? Do they cause excess CPU strain?
2. Do search keys impact client load times?
3. What are some clever ways you've seen search keys used?
4. What are some really bad ways you've seen search keys used?
5. Why would anybody use search keys with tag unchecked?
6. Is there an advantage to having a search key with tag unchecked vs a normal string metadata field for Config/Data?

Solved! Go to Solution.

Labels
  • SCADA
Share
Reply

Accepted Solutions
sbeadle
Sisko sbeadle Sisko
Sisko
‎2019-11-26 02:05 PM
0 Likes
0
270
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content
‎2019-11-26 02:05 PM

Re: [Imported] Search Keys -- Good or Bad?

>>Responses imported from previous forum


Reply From User: adamwoodland, posted: 2019-09-30 22:28:00
Search keys are the original metadata, the standard metadata fields only came into the product about 12 years ago based on the limitations of search keys.

They're great when used correctly, basically without the tag they're an indexed lookup, with the tag ticked they're a unique indexed lookup. What that means is SQL queries that use them in there WHERE clause are more efficient that those with a standard string metadata field (which isn't indexed).

To answer your questions:

1. Search keys are only stored in the config stream, and as they have an index they use more CPU effort when updating. What this means really is if the content of the fields are changing 'often' then search keys are probably not the best option (compared to say standard string metadata fields against the Data stream). One of the whole keeping Config and Data streams separate was to minimize the data flushed to disk with each point value update, and back with ClearSCADA on NT4 days the disk impacts was significant. Now days disks access is so much faster the actually impact of Data and Config streams on disk is minimal but still needs to be considered for other things like network bandwidth.

2. Depends what you mean by client load times. The indexed efficiencies of search keys should mean SQL queries are quicker for clients to retrieve from the server so the perceived performance should improve

3. Common uses are for say the old tag names from imported systems, i.e. ClearSCADA now has its full OPC name (Group.Group.Group.Object) whereas the tag option allows an alternative mapping of names, i.e. P123SN23 (which may be what old systems may still use to access data via OPC-DA). Not sure of any specifically clever ways, it is all about planning how your SQL queries will query and planning your metadata accordingly

4. Anything that is frequently updated. As mentioned above any really old ClearSCADA systems will likely all be search keys, and so those are bound to have some sub-optimal setup (by current standards) solutions there. Can't think of anything specifically though.

5. When tag is checked you're forcing the content for that search key to be unique per object, that has useful cases but also means you couldn't have some grouping. For example you may store in the search key some common attribute across many parts of the database, an example could be the 'owner' of the asset, and different owners due to maybe contractual or commercial reasons could be dotted across the database. Using a search key could allow a much more efficient search to be done. On a database of a few thousand objects then a table scan rather than a indexed lookup is probably a second or so difference, but when you're dealing with databases of 200,000 to a million objects the impact is significant. Last time I checked I believe you can only have one search key set as tag, so other search keys have to have that option untagged.

6. See above, search keys are indexed, so SQLs using those fields are much quicker. When you start using large databases this becomes very important. But using them at the wrong time on a large database may also cause you more problems


Reply From User: tfranklin, posted: 2019-09-30 23:08:48
[at]adamwoodland very interesting stuff! I can definitely see some benefits to moving a few fields we utilize over to search keys. I'll put some thought into this and see what I can break.

One quick question -- I was browsing the help file and noticed an article for Historic Search Keys. In the 10 minutes I spent clicking around, I couldn't find a way to actually implement one and get it to show up as mentioned in help. Any ideas on what those are vs a normal search key, or how to implement one?


Reply From User: adamwoodland, posted: 2019-09-30 23:47:53
Unfortunately its not a case of a simple change, you'll have to create a new field, copy things over between fields (including setting property overrides as necessary) and then deleting the old field and renaming... frankly a pain and something you probably only really want to do if you are having performance issues with SQL. A dodgy hack of the metadata XML file with a cold restart never used to work and I assume still won't 🙂

I wasn't aware of the term historic search keys so I looked it up. Looks to be the same as search keys, just if you also enable historic (so limited to points) you can see them under search keys in the "OPC Historic" toolbar (much the same as you can see them in the "OPC Data" toolbar under search keys)


Reply From User: tfranklin, posted: 2019-10-01 00:51:57
Completely agree. I'm just considering it all for new builds and making them more efficient. I've converted fields in the past from one data type to another and succeeded in blowing up the server. Lessons were learned. It has been some years but it was indeed a dodgy hack and converting a string to a reference field. I'd rate the experience as a 0/10, do not recommend.


Reply From User: andrewscott, posted: 2019-10-01 08:45:10
The January 2019 monthly updates (for 6.78, 6.79 and 6.80) contain fixes for several problems with converting metadata fields between different types, including converting string fields (containing object names) to reference fields.

See Answer In Context

Share
Reply
  • All forum topics
  • Previous Topic
  • Next Topic
1 Reply 1
sbeadle
Sisko sbeadle Sisko
Sisko
‎2019-11-26 02:05 PM
0 Likes
0
271
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content
‎2019-11-26 02:05 PM

Re: [Imported] Search Keys -- Good or Bad?

>>Responses imported from previous forum


Reply From User: adamwoodland, posted: 2019-09-30 22:28:00
Search keys are the original metadata, the standard metadata fields only came into the product about 12 years ago based on the limitations of search keys.

They're great when used correctly, basically without the tag they're an indexed lookup, with the tag ticked they're a unique indexed lookup. What that means is SQL queries that use them in there WHERE clause are more efficient that those with a standard string metadata field (which isn't indexed).

To answer your questions:

1. Search keys are only stored in the config stream, and as they have an index they use more CPU effort when updating. What this means really is if the content of the fields are changing 'often' then search keys are probably not the best option (compared to say standard string metadata fields against the Data stream). One of the whole keeping Config and Data streams separate was to minimize the data flushed to disk with each point value update, and back with ClearSCADA on NT4 days the disk impacts was significant. Now days disks access is so much faster the actually impact of Data and Config streams on disk is minimal but still needs to be considered for other things like network bandwidth.

2. Depends what you mean by client load times. The indexed efficiencies of search keys should mean SQL queries are quicker for clients to retrieve from the server so the perceived performance should improve

3. Common uses are for say the old tag names from imported systems, i.e. ClearSCADA now has its full OPC name (Group.Group.Group.Object) whereas the tag option allows an alternative mapping of names, i.e. P123SN23 (which may be what old systems may still use to access data via OPC-DA). Not sure of any specifically clever ways, it is all about planning how your SQL queries will query and planning your metadata accordingly

4. Anything that is frequently updated. As mentioned above any really old ClearSCADA systems will likely all be search keys, and so those are bound to have some sub-optimal setup (by current standards) solutions there. Can't think of anything specifically though.

5. When tag is checked you're forcing the content for that search key to be unique per object, that has useful cases but also means you couldn't have some grouping. For example you may store in the search key some common attribute across many parts of the database, an example could be the 'owner' of the asset, and different owners due to maybe contractual or commercial reasons could be dotted across the database. Using a search key could allow a much more efficient search to be done. On a database of a few thousand objects then a table scan rather than a indexed lookup is probably a second or so difference, but when you're dealing with databases of 200,000 to a million objects the impact is significant. Last time I checked I believe you can only have one search key set as tag, so other search keys have to have that option untagged.

6. See above, search keys are indexed, so SQLs using those fields are much quicker. When you start using large databases this becomes very important. But using them at the wrong time on a large database may also cause you more problems


Reply From User: tfranklin, posted: 2019-09-30 23:08:48
[at]adamwoodland very interesting stuff! I can definitely see some benefits to moving a few fields we utilize over to search keys. I'll put some thought into this and see what I can break.

One quick question -- I was browsing the help file and noticed an article for Historic Search Keys. In the 10 minutes I spent clicking around, I couldn't find a way to actually implement one and get it to show up as mentioned in help. Any ideas on what those are vs a normal search key, or how to implement one?


Reply From User: adamwoodland, posted: 2019-09-30 23:47:53
Unfortunately its not a case of a simple change, you'll have to create a new field, copy things over between fields (including setting property overrides as necessary) and then deleting the old field and renaming... frankly a pain and something you probably only really want to do if you are having performance issues with SQL. A dodgy hack of the metadata XML file with a cold restart never used to work and I assume still won't 🙂

I wasn't aware of the term historic search keys so I looked it up. Looks to be the same as search keys, just if you also enable historic (so limited to points) you can see them under search keys in the "OPC Historic" toolbar (much the same as you can see them in the "OPC Data" toolbar under search keys)


Reply From User: tfranklin, posted: 2019-10-01 00:51:57
Completely agree. I'm just considering it all for new builds and making them more efficient. I've converted fields in the past from one data type to another and succeeded in blowing up the server. Lessons were learned. It has been some years but it was indeed a dodgy hack and converting a string to a reference field. I'd rate the experience as a 0/10, do not recommend.


Reply From User: andrewscott, posted: 2019-10-01 08:45:10
The January 2019 monthly updates (for 6.78, 6.79 and 6.80) contain fixes for several problems with converting metadata fields between different types, including converting string fields (containing object names) to reference fields.

See Answer In Context

Share
Reply
Top Experts
User Count
sbeadle
Sisko sbeadle Sisko
1
BevanWeiss
Admiral BevanWeiss
1
See More Top Experts
Find a Service Provider
Find a certified partner to help you address your integration, installation, maintenance and project needs.
View all Providers
Support

Have a question? Please contact us with details, and we will respond.

Contact Us
FAQ

Look through existing questions to find popular answers.

Learn More
About

Want to know more about Exchange and its possibilities?

Learn More

Full access is just steps away!

Join Exchange for FREE and get unlimited access to our global community of experts.

Connect with Peers & Experts

Discuss challenges in energy and automation with 30,000+ experts and peers.

Get Support in Our Knowledge Base

Find answers in 10,000+ support articles to help solve your product and business challenges.

Ask Questions. Give Solutions

Find peer based solutions to your questions. Provide answers for fellow community members!

Register today for FREE

Register Now

Already have an account?Log in

About Us FAQ Terms & Conditions Privacy Notice Change your cookie settings
©2020, Schneider Electric