Table of Contents

Search

  1. Preface
  2. RulePoint
  3. RulePoint Concepts
  4. Using RulePoint
  5. RulePoint Objects
  6. Working with Topics
  7. Working with Connections
  8. Working with Sources
  9. Working with Responders
  10. Working with Responses
  11. Working with Watchlists
  12. Working with Analytics
  13. DRQL
  14. Working with Rules
  15. Working with Alerts
  16. Setting Access Controls
  17. Troubleshooting RulePoint Issues
  18. Connecting to an Ultra Messaging Application
  19. Creating an Ultra Messaging JMS Source

User Guide

User Guide

Topic Aliases in DRQL

Topic Aliases in DRQL

Topic aliases in DRQL helps you differentiate and reference multiple topics in a rule. You do not require an alias when you use a single topic. You define aliases in a WHEN statement so that you can easily reference multiple topics in other parts of the rule.
In the following example, an alias for stock is not required:
WHEN 1 stock
If a rule uses multiple topics, you must use an alias. You must specify an alias for the first topic, such as s for stock which is a stock event. Specify a second unique alias for the second topic, such as n for news which is a news event.
WHEN 1 stock s, 1 news n
If you use an alias as reference within the condition of a rule, you must also use the alias in the responder parameters as opposed to using the dotted topic name as reference. Avoid mixing the use of one reference type with the other in the same rule.
You can then use these aliases to identify the topic for which you want to evaluate a particular property. For example, in the following rule, s.symbol indicates that you want to evaluate the symbol property of the stock event. Also, n.headline indicates that you want to evaluate the headline property of the News event.
WHEN 1 stock s, 1 news n WITH s.symbol = "XYZ" OR n.headline contains "XYZ"

0 COMMENTS

We’d like to hear from you!